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

Support prune command for images, containers, volumes and system #648

Closed
mcekovic opened this issue Dec 23, 2021 · 5 comments · Fixed by #1264
Closed

Support prune command for images, containers, volumes and system #648

mcekovic opened this issue Dec 23, 2021 · 5 comments · Fixed by #1264
Labels
enhancement New feature or request

Comments

@mcekovic
Copy link

mcekovic commented Dec 23, 2021

Nerdctl is a great tool, but when used for experimenting it is often needed to quickly delete the remains of experiments.
Support for:

  • nerdctl image prune (--all --force)
  • nerdctl container prune (--force)
  • nerdctl volume prune (--force)
  • nerdctl system prune (--all --force --volumes)

like in Docker would much help.

@fahedouch fahedouch added the enhancement New feature or request label Dec 23, 2021
@AkihiroSuda
Copy link
Member

SGTM, but needs to make sure:

  • Non-nerdctl objects must not be pruned
  • nerdctl system prune should not prune networks because networks are not namespaced objects

@AkihiroSuda
Copy link
Member

AkihiroSuda commented Dec 23, 2021

Alternatively we can just have nerdctl namespace rm and call it a day.
This command will remove all objects in the specified namespace.

@mcekovic
Copy link
Author

nerdctl namespace rm seems could do the job and is probably easier to implement.

click2cloud-lamda added a commit to Click2Cloud/nerdctl that referenced this issue Apr 20, 2022
click2cloud-lamda added a commit to Click2Cloud/nerdctl that referenced this issue Apr 20, 2022
click2cloud-lamda added a commit to Click2Cloud/nerdctl that referenced this issue Apr 20, 2022
click2cloud-lamda added a commit to Click2Cloud/nerdctl that referenced this issue Apr 20, 2022
click2cloud-lamda added a commit to Click2Cloud/nerdctl that referenced this issue Apr 20, 2022
…and added changes to README.md

Signed-off-by: Raymond Mathew <[email protected]>
click2cloud-lamda added a commit to Click2Cloud/nerdctl that referenced this issue Apr 20, 2022
…and added changes to README.md

Signed-off-by: Raymond Mathew <[email protected]>
click2cloud-lamda added a commit to Click2Cloud/nerdctl that referenced this issue Apr 20, 2022
…and added changes to README.md

Signed-off-by: Raymond Mathew <[email protected]>
click2cloud-lamda added a commit to Click2Cloud/nerdctl that referenced this issue Apr 20, 2022
…and added changes to README.md

Signed-off-by: Raymond Mathew <[email protected]>
click2cloud-lamda added a commit to Click2Cloud/nerdctl that referenced this issue Apr 25, 2022
…and added changes to README.md

Signed-off-by: Raymond Mathew <[email protected]>
click2cloud-lamda added a commit to Click2Cloud/nerdctl that referenced this issue May 6, 2022
…and added changes to README.md

Signed-off-by: Raymond Mathew <[email protected]>
click2cloud-lamda added a commit to Click2Cloud/nerdctl that referenced this issue May 6, 2022
…and added changes to README.md

Signed-off-by: Raymond Mathew <[email protected]>
click2cloud-lamda added a commit to Click2Cloud/nerdctl that referenced this issue May 6, 2022
…and added changes to README.md

Signed-off-by: Raymond Mathew <[email protected]>
click2cloud-lamda added a commit to Click2Cloud/nerdctl that referenced this issue May 6, 2022
…and added changes to README.md

Signed-off-by: Raymond Mathew <[email protected]>
click2cloud-lamda added a commit to Click2Cloud/nerdctl that referenced this issue May 6, 2022
…and added changes to README.md

Signed-off-by: Raymond Mathew <[email protected]>
click2cloud-lamda added a commit to Click2Cloud/nerdctl that referenced this issue May 6, 2022
…and added changes to README.md

Signed-off-by: Raymond Mathew <[email protected]>
click2cloud-lamda added a commit to Click2Cloud/nerdctl that referenced this issue May 10, 2022
…and added changes to README.md

Signed-off-by: Raymond Mathew <[email protected]>
@AkihiroSuda
Copy link
Member

https://github.com/containerd/nerdctl/releases/tag/v0.22.0

nerdctl v0.22.0 supports nerdctl image prune --all, nerdctl container prune, and nerdctl volume prune.
No support for nerdctl network prune and nerdctl system prune yet though.

@junnplus
Copy link
Member

nerdctl network prune and nerdctl system prune already support and should be released in v0.22.1.

@AkihiroSuda AkihiroSuda linked a pull request Jul 27, 2022 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
4 participants