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

fix: image usage by containers #5663

Merged
merged 1 commit into from Jan 25, 2024
Merged

Conversation

benoitf
Copy link
Collaborator

@benoitf benoitf commented Jan 24, 2024

What does this PR do?

Image usage should only match if the image tag is matching as well

Screenshot / video of UI

image

What issues does this PR fix or reference?

fixes #5583

How to test this PR?

Unit tests

try the case reported by the issue (or another usage)

@benoitf benoitf requested a review from a team as a code owner January 24, 2024 09:16
@benoitf benoitf requested review from dgolovin, feloy and cbr7 and removed request for a team January 24, 2024 09:16
fixes containers#5583
Signed-off-by: Florent Benoit <fbenoit@redhat.com>
@cbr7
Copy link
Contributor

cbr7 commented Jan 24, 2024

@benoitf I checked the fix on this branch and the original issue is indeed fixed, however I've noticed a somewhat related problem if the user uses the Prune functionality on the duplicate images, while individual copies can now be deleted, the prune bulk action still sees the copies as being in use. I've attached a video of the behavior.

Screen.Recording.2024-01-24.at.12.32.11.mov

@benoitf
Copy link
Collaborator Author

benoitf commented Jan 24, 2024

@cbr7 we delegate the prune operation to the container engine (using the REST API)

it won't prune the image as it's used. From the container engine POV, there is only one image with multiple tags.
We display one line per tag for easiness but pruning the image is either removing the image or not, not untagging some unused tags

@benoitf benoitf merged commit 2fcbd46 into containers:main Jan 25, 2024
8 checks passed
@podman-desktop-bot podman-desktop-bot added this to the 1.8.0 milestone Jan 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

All copies of an image are flagged as in use if only one of them is in use
3 participants