Skip to content

Commit

Permalink
fix(ci): Restore push of sbom to GitHub release (chainloop-dev#1797)
Browse files Browse the repository at this point in the history
Signed-off-by: Javier Rodriguez <[email protected]>
  • Loading branch information
javirln authored Feb 10, 2025
1 parent 9fe60f5 commit dfe10b1
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -109,12 +109,14 @@ jobs:
for entry in $images; do
# exclude latest tag
if [[ $entry != *latest ]]; then
syft -o cyclonedx-json=/tmp/sbom.cyclonedx.json $entry
material_name="$(echo $entry | sed 's#.*/##')"
syft -o cyclonedx-json=/tmp/sbom-$material_name.cyclonedx.json $entry
chainloop attestation add --value $entry --kind CONTAINER_IMAGE --attestation-id ${{ env.ATTESTATION_ID }}
chainloop attestation add --value /tmp/sbom.cyclonedx.json --attestation-id ${{ env.ATTESTATION_ID }}
chainloop attestation add --value /tmp/sbom-$material_name.cyclonedx.json --kind SBOM_CYCLONEDX_JSON --attestation-id ${{ env.ATTESTATION_ID }}
# Upload the SBOM to the release
# gh release upload ${{ github.ref_name }} /tmp/sbom-$material_name.cyclonedx.json --clobber
gh release upload ${{ github.ref_name }} /tmp/sbom-$material_name.cyclonedx.json --clobber
fi
done
Expand Down

0 comments on commit dfe10b1

Please sign in to comment.