-
Notifications
You must be signed in to change notification settings - Fork 15
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
How to access the built image sha #49
Comments
@dhensby How would you want to use this? an example would be helpful. |
So using something like notion you (ideally) want to get your hands on the raw image sha for signing. It's not much more than: The issue is that builds don't seem to have a predictable tag nor a way to get your hand on it so you can resolve the hash locally. Though, looking at the code - perhaps if I can set |
If there was a way to set this |
Not currently, but it wouldn't be difficult to add. Also, and I'll have to confirm, but I might just be able to mutate the |
Additionally as I'm working through it now, I'm not sure that would work if you were using buildx as the build + push happen in the same docker command and the images are not stored locally. it may not effect you, but something to think about. |
The images are available locally if the |
Yes. So nothing to worry about here, I'm just thinking out loud. |
Looking for something similar in order to take advantage of actions/attest-build-provenance in GitHub CI. Right now, this seems only to be possible by publishing the docker image using docker/build-push-action after semantic-release. |
How would you expect to get access to it? |
The final image sha, or the tag of an image? |
The signing programs can complain if you don't give the actual image sha, so that would be idea. |
I'm not sure either... echo "version=$(npm run env | grep npm_package_version | cut -d '=' -f 2)" >> $GITHUB_OUTPUT I can then reuse the new version in any of the following jobs. |
At the moment I use the
Then I use that version to do the signing with Where $IMAGE is and env var constructed as so: Edit (for clarity): This causes notation to complain because it wants a sha instead - and that's what I'd like to be able to get my hands on somehow even if it means another |
Ah, I see. Thanks, that helps. I think mutating the release object could work. Provided semantic release isn't re-creating it for each plugin |
I'm looking at implementing docker image signing as part of our release process. To do this, ideally we'd have access to the sha of the built image. Is there any way to expose this value so that it can be used in an
exec
step or similar?The text was updated successfully, but these errors were encountered: