Created
June 4, 2018 14:12
-
-
Save rcbop/3183b09a7db0cbcd9d9889da26918e04 to your computer and use it in GitHub Desktop.
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/bash | |
docker images --no-trunc --format '{{.ID}} {{.CreatedSince}}' | grep months | awk '$2 > 3 { print $1 }' | xargs -r docker rmi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment