I have couple of dangled images (images that appear in docker images
with none tag). To clean them, based on LABEL, the usual command is: docker image prune -a --force --filter="label=some-key=some-value"
.
However, this command doesn't prune dangled images that have container associated. Irrespective of whether the container is started or stopped.
I cannot run docker container prune -f
since I don't want to prune all stopped containers. Is there a command to prune images and the containers associated with the image based on image label?