The super-simple docker-compose cheatsheet
Run these commands in the directory (or git repo) where docker-compose.yml
is located!
Start all services
docker-compose up -d
-d
means run in background (= daemonize).
Stop all services
docker-compose down
Restart all services
docker-compose restart
Update containers
docker-compose pull
docker-compose restart
View logs
docker-compose logs
To view and follow use
docker-compose logs -f
Start a specific service (and all the services it depends on)
docker-compose start myservice
Show info about which container images are being used
docker-compose images