I need some kind of Docker behaviour. Imagine docker image name is imagename
and image also have tag(1, 2, 3 ...). Now I want to delete all images with the name imagename
and with the tag that isn't x
. For example if I have images:
imagename:1
imagename:2
imagename:3
imagename:4
imagename:5
imagename:6
with 1, 2, 3 ...6 tags, and I want to have only one Image with name imagename
and tag 6, what command should I run?