Last active
October 4, 2019 18:19
-
-
Save mitjafelicijan/1e8868da053f0406a7d196e0eb679969 to your computer and use it in GitHub Desktop.
Stop and clean all Docker containers/images
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# stop all containers | |
docker stop $(docker ps -q) | |
# delete all containers | |
docker rm $(docker ps -a -q) | |
# delete all images | |
docker rmi $(docker images -q) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment