Created
June 22, 2016 02:54
-
-
Save iwat/eda999d2d78a48af4932167cc7f18e49 to your computer and use it in GitHub Desktop.
Clean unused docker images and volumes.
This file contains 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/sh | |
docker volume ls -f dangling=true -q | xargs docker volume rm | |
docker rmi $(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