Resolve image name to ID before fetching digest to resolve false drift #92
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
EL9.5 ships podman v5 with skopeo 1.16 up from 1.14. The behaviour of how image digests are reported has changed, causing
podman::container
to consider needing to fetch a new image on every run and unwanted container restarts.podman image inspect --format='{{.Digest}}'
now returns different hashes depending on whether an image ID or a tag is given as argument.Skopeo reports the image digest in the registry as if podman image inspect were called with the image ID.
This code resolves the given image name (which might be an ID or a Tag) into the ID before trying to fetch the digest. This prevents the false drift.
Fixes #91