Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save thiagomgo/16603603867c645df284a3eea72720c7 to your computer and use it in GitHub Desktop.
Save thiagomgo/16603603867c645df284a3eea72720c7 to your computer and use it in GitHub Desktop.
Kill all container, remove all images and stop all containers
#stop all containers:
docker kill $(docker ps -q)
#remove all containers
docker rm $(docker ps -a -q)
#remove all old containers
docker rm $(docker ps --filter "status=exited" -q)
#remove all docker images
docker rmi $(docker images -q)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment