Docker Command cheatsheet
Docker
Virtualization
@see Docker compose commands cheatsheet
List running containers
- Use the
-a
flag to list all container.
docker ps
List images
docker images
Remove images
docker rmi <image1> <image2>
Open a shell inside a container
docker exec -it <container_name> bash
Remove unused volumes
docker volume prune
Remove unused networks
docker network prune
Inspect container logs
- Use the
--follow
flag to inspect the live logs.
docker logs --details <container>