File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -193,3 +193,17 @@ jobs:
193193 run : |
194194 set -euo pipefail
195195 cosign attest --yes --type spdxjson --predicate sbom.spdx.json "${{ steps.image.outputs.image }}@${{ steps.image.outputs.digest }}"
196+
197+ - name : Publish summary
198+ shell : bash
199+ run : |
200+ set -euo pipefail
201+ {
202+ echo "### crispr-gpu CPU image published"
203+ echo ""
204+ echo "- Image: \`${{ steps.image.outputs.image }}@${{ steps.image.outputs.digest }}\`"
205+ echo "- Cosign signature ref: \`${{ steps.cosign.outputs.signature_ref }}\`"
206+ echo "- Git ref: \`${{ steps.vars.outputs.tag }}\`"
207+ echo "- Git sha: \`${{ steps.git.outputs.sha }}\`"
208+ echo "- Workflow run id: \`${{ github.run_id }}\`"
209+ } >> "$GITHUB_STEP_SUMMARY"
Original file line number Diff line number Diff line change @@ -21,17 +21,19 @@ DIGEST="sha256:..." # immutable digest, not a tag
2121Verify the signature for the digest:
2222``` bash
2323cosign verify \
24- --certificate-identity-regexp ' ^https://github.com/omniscoder/crispr-gpu/.github/workflows/docker-publish\.yml@refs/tags/v[0-9]+\.[0-9]+\.[0-9]+$' \
24+ --certificate-identity-regexp ' ^https://github.com/omniscoder/crispr-gpu/.github/workflows/docker-publish\.yml@refs/( tags/v[0-9]+\.[0-9]+\.[0-9]+|heads/master) $' \
2525 --certificate-issuer ' https://token.actions.githubusercontent.com' \
2626 " ${IMAGE} @${DIGEST} "
2727```
2828
29+ If you want * strict release-only* verification, tighten the identity to ` @refs/tags/vX.Y.Z ` instead of allowing ` @refs/heads/master ` .
30+
2931## Verify an SBOM attestation exists (same digest)
3032
3133``` bash
3234cosign verify-attestation \
3335 --type spdxjson \
34- --certificate-identity-regexp ' ^https://github.com/omniscoder/crispr-gpu/.github/workflows/docker-publish\.yml@refs/tags/v[0-9]+\.[0-9]+\.[0-9]+$' \
36+ --certificate-identity-regexp ' ^https://github.com/omniscoder/crispr-gpu/.github/workflows/docker-publish\.yml@refs/( tags/v[0-9]+\.[0-9]+\.[0-9]+|heads/master) $' \
3537 --certificate-issuer ' https://token.actions.githubusercontent.com' \
3638 " ${IMAGE} @${DIGEST} "
3739```
@@ -48,4 +50,3 @@ docker run --rm \
4850 -v " $( pwd) /reports_docker:/out" \
4951 " ${IMAGE} @${DIGEST} "
5052```
51-
You can’t perform that action at this time.
0 commit comments