Running docker-compose
We normally run containers using the docker
command, but what if we want to run more than one container in one go? This is where docker-compose
comes to the rescue. The tool allows you to configure the different containers that you want to run as a single unit. It also allows different kinds of configurations for different containers – for example, container A can communicate via the network with container B but not with container C.
The docker-compose
tool that we are using in this book is v2, which is the recommended version. You can find instructions for installing the tool for different operating systems here – https://docs.docker.com/compose/install/other/.
To make it easy to run both Prometheus and Jaeger, you can use docker-compose
. The docker-compose.yml
file looks as follows:
version: '3.3' services: jaeger: image: jaegertracing/all-in-one:latest ports: ...