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 -f/--force flag in podman image prune #4410

Closed
XVilka opened this issue Nov 1, 2019 · 4 comments · Fixed by #4512
Closed

Support -f/--force flag in podman image prune #4410

XVilka opened this issue Nov 1, 2019 · 4 comments · Fixed by #4512
Labels
Good First Issue This issue would be a good issue for a first time contributor to undertake. kind/feature Categorizes issue or PR as related to a new feature. locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments.

Comments

@XVilka
Copy link

XVilka commented Nov 1, 2019

/kind feature

Description

Docker CLI has a -f flag for the docker image prune command. So for podman to be compatible with docker, especially in scripts, at least it would be better not to show an error:

Steps to reproduce the issue:

  1. podman image prune -f

Describe the results you received:

Error: unknown shorthand flag: 'f' in -f

Describe the results you expected:

Should not throw an error on both -f and --force flags used.

@openshift-ci-robot openshift-ci-robot added the kind/feature Categorizes issue or PR as related to a new feature. label Nov 1, 2019
@rhatdan
Copy link
Member

rhatdan commented Nov 1, 2019

@XVilka Interested in adding these flags. Looks like we are also missing
--filter filter Provide filter values (e.g. 'until=')

@rhatdan rhatdan added the Good First Issue This issue would be a good issue for a first time contributor to undertake. label Nov 1, 2019
@rhatdan
Copy link
Member

rhatdan commented Nov 1, 2019

BTW What kind of confirmation is Docker doing? I don't think Podman does any prompting at this point.

@XVilka
Copy link
Author

XVilka commented Nov 1, 2019

$ docker image prune
WARNING! This will remove all dangling images.
Are you sure you want to continue? [y/N]

Even if podman doesn't ask, at least it should not report an error if -f flag is used.

@rhatdan
Copy link
Member

rhatdan commented Nov 1, 2019

I agree.

tylarb added a commit to tylarb/libpod that referenced this issue Nov 15, 2019
Add a -f, --force flag to images prune. As there was previously no
prompt to force prune images, this commit does nothing to add such a
question, only make the cli command compatible with docker cli.

Resolves containers#4410

Signed-off-by: Tyler Ramer <tyaramer@gmail.com>
@github-actions github-actions bot added the locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments. label Sep 23, 2023
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 23, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Good First Issue This issue would be a good issue for a first time contributor to undertake. kind/feature Categorizes issue or PR as related to a new feature. locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments.
Projects
None yet
3 participants