Created
May 13, 2016 22:18
-
-
Save aztecrex/cbbb9d597a84b2ceeec73887dc768e49 to your computer and use it in GitHub Desktop.
delete tagless images from ECR
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
this is not quite it... | |
aws ecr list-images --repository-name MyRepository --query 'imageIds?type(imageTag)!=`string`.imageDigest' --output text | while read line; do aws ecr batch-delete-image --repository-name MyRepository --image-ids imageDigest=$line; done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment