Version : ' 3.9' # optional since v1.27.0 services : web : build. You can alternatively run docker-compose up using the docker-compose binary. Run docker compose up and the Docker compose command starts and runs your entire app. So they can be run together in an isolated environment. Using Compose is basically a three-step process:ĭefine your app’s environment with a Dockerfile so it can be reproducedĭefine the services that make up your app in docker-compose.yml
You can learn more about each case in Common Use To learn more about all the features of Compose,Ĭompose works in all environments: production, staging, development, testing, as Then, with a single command, you create and start all the servicesįrom your configuration. With Compose, you use a YAML file to configure your application’s services. Looking for Compose file reference? Find the latest version here.Ĭompose is a tool for defining and running multi-container Docker applications.