Skip to content

ci: add SBOM generation and artifact attestations to releases#80

Merged
wizzomafizzo merged 1 commit into
mainfrom
chore/attestations
Apr 10, 2026
Merged

ci: add SBOM generation and artifact attestations to releases#80
wizzomafizzo merged 1 commit into
mainfrom
chore/attestations

Conversation

@wizzomafizzo

@wizzomafizzo wizzomafizzo commented Apr 10, 2026

Copy link
Copy Markdown
Member

Summary

  • Add Sigstore-signed build provenance attestations to release artifacts
  • Generate SPDX SBOM and attach as both an attestation and a release asset
  • Release artifacts verifiable with gh attestation verify

Summary by CodeRabbit

  • Chores
    • Release artifacts now include Software Bill of Materials (SBOM) and build attestations, providing enhanced supply chain transparency and verification for downloads.

Add Sigstore-signed build provenance and SBOM attestations to the
build workflow. Tag-push releases now include:
- SLSA build provenance attestation (verifiable with gh attestation verify)
- SPDX SBOM generation and attestation
- SBOM uploaded as a release asset
@coderabbitai

coderabbitai Bot commented Apr 10, 2026

Copy link
Copy Markdown
📝 Walkthrough

Walkthrough

The workflow configuration expands job permissions and adds security artifact generation for tag-triggered releases. It now generates an SPDX JSON SBOM, creates build provenance and SBOM attestations using actions/attest, and uploads both the tarball(s) and SBOM file to the release.

Changes

Cohort / File(s) Summary
Build Workflow Configuration
.github/workflows/build.yaml
Expanded job permissions to include id-token: write and attestations: write. Added SBOM generation via cyclonedx-bom and creation of two attestations (build provenance and SBOM) for tag-triggered releases. Updated release step to upload both tarball and sbom.spdx.json.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related PRs

Poem

🐰 Hops of joy through the build pipeline swift,
Security seals with provenance gift,
SBOM attestations bloom, so fine,
Every artifact traced—a supply chain's sign!

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately and concisely describes the main change: adding SBOM generation and artifact attestations to the CI/CD release process.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch chore/attestations

Comment @coderabbitai help to get the list of available commands and usage tips.

@codecov

codecov Bot commented Apr 10, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick comments (1)
.github/workflows/build.yaml (1)

26-29: Scope elevated permissions to a release-only job.

Line 28 and Line 29 expand privileges for all build job executions. Consider moving attestation/release steps into a separate tag-only job so non-release runs don’t carry id-token: write and attestations: write.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.github/workflows/build.yaml around lines 26 - 29, The build job currently
grants elevated permissions (id-token: write and attestations: write) under the
permissions block, which should be limited to release/tag runs; create a new job
(e.g., release or attest) that is triggered only on tag events and move the
id-token: write and attestations: write permissions and any attestation/release
steps into that job, while keeping the existing build job's permissions minimal
(remove id-token and attestations from build and leave only what it needs, e.g.,
contents: write or read) so non-release runs do not carry elevated privileges.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Nitpick comments:
In @.github/workflows/build.yaml:
- Around line 26-29: The build job currently grants elevated permissions
(id-token: write and attestations: write) under the permissions block, which
should be limited to release/tag runs; create a new job (e.g., release or
attest) that is triggered only on tag events and move the id-token: write and
attestations: write permissions and any attestation/release steps into that job,
while keeping the existing build job's permissions minimal (remove id-token and
attestations from build and leave only what it needs, e.g., contents: write or
read) so non-release runs do not carry elevated privileges.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 29eef547-0ca1-4712-8f40-7e9b5a6d1d0d

📥 Commits

Reviewing files that changed from the base of the PR and between cd0cc78 and b9c1e43.

📒 Files selected for processing (1)
  • .github/workflows/build.yaml

@wizzomafizzo
wizzomafizzo merged commit e34d390 into main Apr 10, 2026
6 checks passed
@wizzomafizzo
wizzomafizzo deleted the chore/attestations branch April 10, 2026 03:03
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.

1 participant