Docker-compose for apm quickstart[ Done]

HI, I try to configure the docker-compose , but i can not add apm-server into kibana.

So Is there docker-compose.yml for apm quickstart ?


i have setup with. GitHub - lizozom/docker-elastic-observability-with-apm: Docker compose setup of an observability use case. Reporting metrics and traces from a nodejs app to Elasticsearch using APM Server using APM RUM and APM Node.js agents.

Welcome to our community, @shalk!

We do have a docker-compose.yaml file in the APM Server GitHub repository: apm-server/docker-compose.yml at main · elastic/apm-server · GitHub. It's meant to be for development since it uses the last snapshot builds avaialble, but you can replace the snapshot versions with the Elastic Stack version you want to run.

Additionally, our docs have some more information on how to configure and get started Self manage APM Server | Elastic Observability [8.14] | Elastic.

Thank you for your reply!

I found the file apm-server/docker-compose.yml at main · elastic/apm-server · GitHub, But apm-server not in this file

i don't know how to configure the apm-server in docker-compose.yml.

Our docs should have all the infromation you need to run APM Server in Docker: Run APM Server on Docker | Elastic Observability [8.14] | Elastic

1 Like

You can give a try to this docker-compose.yml.

You can spin below stacks -

  • Elasticsearch
  • Kibana
  • Logstash
  • APM Server
1 Like

I have find a docker-compose file.

I also try GitHub - ashishtiwari1993/elastic-docker: Run elastic stack instances on docker. Setup elastic cluster with single docker-compose.yml file.
i just update stack version to 8.14.1, some exception happen

apm-1       | {"log.level":"info","@timestamp":"2024-07-04T11:41:36.065Z","log.logger":"beater","log.origin":{"function":"*Runner).Run.func1","":"beater/beater.go","file.line":170},"message":"stopping apm-server... waiting maximum of 30s for queues to drain","":"apm-server","ecs.version":"1.6.0"}
apm-1       | {"log.level":"info","@timestamp":"2024-07-04T11:41:36.065Z","log.origin":{"function":"*Beat).Run","":"beatcmd/beat.go","file.line":394},"message":"apm-server stopped.","":"apm-server","ecs.version":"1.6.0"}
apm-1       | Error: open /usr/share/apm-server/certs/es01/es01.crt: permission denied /usr/share/apm-server/certs/es01/es01.crt
apm-1       | open /usr/share/apm-server/certs/ca/ca.crt: permission denied reading <nil>
apm-1       | {"log.level":"error","@timestamp":"2024-07-04T11:41:36.065Z","log.logger":"tls","log.origin":{"function":"","":"tlscommon/tls.go","file.line":65},"message":"Failed reading certificate file /usr/share/apm-server/certs/es01/es01.crt: open /usr/share/apm-server/certs/es01/es01.crt: permission denied","":"apm-server","ecs.version":"1.6.0"}
apm-1       | {"log.level":"error","@timestamp":"2024-07-04T11:41:36.065Z","log.logger":"tls","log.origin":{"function":"","":"tlscommon/tls.go","file.line":216},"message":"Failed reading CA certificate: open /usr/share/apm-server/certs/ca/ca.crt: permission denied","":"apm-server","ecs.version":"1.6.0"}
apm-1       | Usage:
apm-1       |   apm-server [flags]
apm-1       |   apm-server [command]
apm-1       |
apm-1       | Available Commands:
apm-1       |   apikey      Manage API Keys for communication between APM agents and server (deprecated)
apm-1       |   export      Export current config
apm-1       |   help        Help about any command
apm-1       |   keystore    Manage secrets keystore
apm-1       |   run         Run APM Server
apm-1       |   test        Test config
apm-1       |   version     Show current version info
apm-1       |
apm-1       | Flags:
apm-1       |   -E, --E setting=value      Configuration overwrite
apm-1       |   -N, --N                    Disable actual publishing for testing
apm-1       |   -c, --c string             Configuration file, relative to path.config (default "apm-server.yml")
apm-1       |       --cpuprofile string    Write cpu profile to file
apm-1       |   -d, --d stringArray        Enable certain debug selectors
apm-1       |   -e, --e                    Log to stderr and disable syslog/file output
apm-1       |       --environment string   Set the environment in which the process is running (default "default")
apm-1       |   -h, --help                 help for apm-server
apm-1       |       --httpprof string      Start pprof http server
apm-1       |       --memprofile string    Write memory profile to this file
apm-1       |       --path.config string   Configuration path
apm-1       | string     Data path
apm-1       |       --path.home string     Home path
apm-1       |       --path.logs string     Logs path
apm-1       |       --strict.perms         Strict permission checking on config files (default true)
apm-1       |   -v, --v                    Log at INFO level
apm-1       |
apm-1       | Use "apm-server [command] --help" for more information about a command.
apm-1       |
apm-1 exited with code 1

Let me check @shalk