You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Description docker system prune -f is supposed to remove dangling images but images tagged <none> aren't necessarily removed.
Meanwhile, docker rmi $(docker images -f dangling=true) will remove more images.
Something is not coherent in one of those?
Steps to reproduce the issue:
Pull an image by a digest (docker pull image@sha256:...)
docker system prune -f
docker rmi $(docker images -f dangling=true)
Describe the results you received:
3rd command above still deletes an image.
Describe the results you expected:
Prune should have done all the work before the last command.
Additional information you deem important (e.g. issue happens only occasionally):
Output of docker version:
Client:
Version: 1.13.0
API version: 1.25
Go version: go1.7.3
Git commit: 49bf474
Built: Tue Jan 17 09:58:26 2017
OS/Arch: linux/amd64
Server:
Version: 1.13.0
API version: 1.25 (minimum version 1.12)
Go version: go1.7.3
Git commit: 49bf474
Built: Tue Jan 17 09:58:26 2017
OS/Arch: linux/amd64
Experimental: false
I would like docker system prune to remove untagged images. If this is not going to be a default behavior, can we have a flag for that? It's useful after pulling newest latest images.
@AlekSi try using the -a flag. By default it was decided not to remove images without a container attached to them as people may just be using the machine as a build machine and doing so would erase their cache.
I use Docker with Drone CI. I don't want to remove, for example, latest mysql:5.7 even if it doesn't have a container, but I want to remove previous versions of this tag. -a would remove the latest version, without this flag previous versions will not be removed.
I wonder what images docker system prune without -a removes?
This issue is about a difference in behavior and definition of the word "dangling". If you want to keep it, then I think:
Help message should be updated to describe what would be removed.
Some flag should be added to remove all untagged images.
Description
docker system prune -f
is supposed to remove dangling images but images tagged<none>
aren't necessarily removed.Meanwhile,
docker rmi $(docker images -f dangling=true)
will remove more images.Something is not coherent in one of those?
Steps to reproduce the issue:
Describe the results you received:
3rd command above still deletes an image.
Describe the results you expected:
Prune should have done all the work before the last command.
Additional information you deem important (e.g. issue happens only occasionally):
Output of
docker version
:Output of
docker info
:Additional environment details (AWS, VirtualBox, physical, etc.):
The text was updated successfully, but these errors were encountered: