← Docker learning pathDocker · Module 7 of 10
Docker Compose
Compose starts a whole multi-container app from one file.
📖 Key ideas
- compose.yaml describes services, their images or builds, ports, volumes and environment.
- docker compose up -d starts everything; docker compose down stops it.
- Services reach each other by service name on a shared network Compose creates.
- depends_on sets start order (but not readiness).
- Great for local development and small deployments.
💡 Real-life example: Compose is the band leader: one signal and the drums, guitar and singer all start together.
compose.yamlFile that defines the app services
ServiceOne container definition in Compose
docker compose upStarts all services
depends_onSets service start order