docker commands
This is a reference article.
Reference articles are written with the help of AI agents, after we have managed to solve a problem.
TL;DR
- Use
docker psto see running containers anddocker logs <container>to debug them.- Use
docker exec -it <container> <cmd>for an interactive shell or one-off commands.- Use
docker compose up/downto start and stop multi-service stacks.
Essential Docker CLI commands for managing containers, images, and services.