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

build: fix iidfile content #975

Closed
wants to merge 3 commits into from
Closed

Conversation

crazy-max
Copy link
Member

fixes #420
fixes docker/build-push-action#461

output the image ID or digest with --iidfile flag and containerimage.digest response depending on the driver and output being used:

  • docker driver : writes the image ID.
  • docker driver with --push: writes the image digest.
  • docker-container driver with --load: writes the image ID.
  • docker-container driver with --push: writes the image digest.

Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
@tonistiigi
Copy link
Member

docker driver with --push: writes the image digest.

Is this the behavior that we want?

@crazy-max
Copy link
Member Author

crazy-max commented Feb 28, 2022

docker driver with --push: writes the image digest.

Is this the behavior that we want?

I see what you mean as the image is in docker store but also pushed to the registry. I agree for feature parity it might be better to keep the image ID for this case. Wonder if we could somehow provide the image digest in the exporter response (other key?) or another flag?

@crazy-max
Copy link
Member Author

#980 will fix the imageID issue with the container driver. About image digest I think it's a misleading issue in our github action with the digest output. Should be called imageid instead and we should change the digest output behavior to only add image digest if image is effectively pushed. WDYT?

@tonistiigi
Copy link
Member

Should be called imageid instead and we should change the digest output behavior to only add image digest if image is effectively pushed. WDYT?

Yes, separate outputs for the action. The digest is filled whenever it is available, not only with push.

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.

Digest output is image ID, not RepoDigest --iidfile contains mismatching id
2 participants