Last active
April 28, 2017 06:54
-
-
Save swcho/1fde11ad651d977122dff5320b62aa0a to your computer and use it in GitHub Desktop.
Docker Commands
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 | |
# http://jimhoskins.com/2013/07/27/remove-untagged-docker-images.html | |
docker rmi $(docker images | grep "^<none>" | awk "{print $3}") |
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 | |
# https://coderwall.com/p/zguz_w/docker-remove-all-exited-containers | |
docker ps -a | grep Exit | cut -d ' ' -f 1 | xargs docker rm |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment