Created
August 26, 2020 13:58
-
-
Save ERPedersen/e817f21c89816712992134d2d114705f to your computer and use it in GitHub Desktop.
Reset docker environment
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
# Remove all containers | |
docker rm $(docker ps -aq) | |
# Remove all images | |
docker rmi $(docker images -q) | |
# Remove the following: | |
# - all stopped containers | |
# - all volumes not used by at least one container | |
# - all networks not used by at least one container | |
# - all dangling images | |
docker system prune |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment