Last active
January 18, 2018 03:29
-
-
Save john20xdoe/25be9852fb9bd632a0b0d9ea2a233e25 to your computer and use it in GitHub Desktop.
Docker clear image commands (local copies)
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
| # stop all instances and remove | |
| docker stop $(docker ps -a -q) && docker rm $(docker ps -a -q) | |
| # force remove wih sudo | |
| docker rm -f -v $(sudo docker ps -a -q) | |
| # remove only untagged | |
| docker rmi -f $(docker images | grep "<none>" | awk "{print \$3}") | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment