Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

verbose option for docker system prune #5665

Open
realyukii opened this issue Dec 3, 2024 · 2 comments
Open

verbose option for docker system prune #5665

realyukii opened this issue Dec 3, 2024 · 2 comments

Comments

@realyukii
Copy link

Description

The following help output didn't have verbose option, so I propose it here

$ docker system prune --help

Usage:  docker system prune [OPTIONS]

Remove unused data

Options:
  -a, --all             Remove all unused images not just dangling ones
      --filter filter   Provide filter values (e.g. "label=<key>=<value>")
  -f, --force           Do not prompt for confirmation
      --volumes         Prune anonymous volumes

It would be nice to know what the system remove and where it is (print location path of removed data)

@thaJeztah
Copy link
Member

I don't think the API provides this information; it returns a list of references (image, volume, network, etc) that have been removed, but the underlying paths on the filesystem (for types that are related to filesystem cleanups) are not returned. Not sure if it's even possible to return those paths for all types and situations, e.g. volumes could be associated with a specific driver, and for images, it's possible that the reference is removed, but some parts still wired up otherwise.

Do you have more information on your use-case?

@realyukii
Copy link
Author

For background: I have half-finished docker build -t project . process, because I deliberately stop it (I have to go to school and the process is take some time to complete), so I decide to prune it and start over.

I was also told by a friend that docker can resume it and I don't need to perform system prune, but it's too late :P

anyway, I just unsure if the docker cli remove the files cleanly, is there a source about which path maintained by docker? so far the one I know is /var/lib/docker.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants