docker compose up --abort-on-container-exit

Category: Docker

docker compose up --abort-on-container-exit

Stop all services when one container exits

Watches the stack and tears everything down as soon as any container exits, instead of leaving the rest running. Pairs with --exit-code-from to propagate that container's exit code. Great for CI test suites built with compose.
Looking for more? Search all 7,657 commands — works offline, in English or Spanish, and fixes typos.