Skip to content

feat(refactor-release): publish release SBOMs - #12869

Draft
DariuszPorowski wants to merge 2 commits into
dp/goreleaser-tag-cutoverfrom
dp/goreleaser-sboms
Draft

DariuszPorowski wants to merge 2 commits into
dp/goreleaser-tag-cutoverfrom
dp/goreleaser-sboms

Conversation

@DariuszPorowski

@DariuszPorowski DariuszPorowski commented Aug 28, 2026

Copy link
Copy Markdown
Member

Summary

Generate SPDX JSON SBOMs for all seven raw rad release binaries with checksum-verified Syft v1.51.1, and attach per-platform SPDX SBOM attestations to the five GoReleaser production images.

Verify the exact CLI SBOM asset set and document structure on draft and published releases. Verify one image attestation per locked production platform before image locking, finalization, and published-release reconciliation. Existing binary names and checksum assets remain unchanged.

This stacked PR depends on #12828.

Draft gate: keep this PR in draft until one RC draft release contains all seven well-formed CLI SBOM assets and valid attestations for every production-image platform.

  • Observe the complete SBOM set on one RC draft release.

Reason for change

PR13 made GoReleaser authoritative for core release artifacts. This additive follow-up uses its native Syft and dockers_v2 integration to expose dependency inventories without creating a parallel publishing path or weakening the existing parity contract.

Fixes #12818

How to test

  • make goreleaser-snapshot GORELEASER_ARGS="--skip=docker" built all 22 targets, generated seven SPDX 2.3 CLI SBOMs, generated no unintended SBOM checksum sidecars, and passed the enhanced output verifier.
  • bash .github/scripts/release-sboms_test.sh
  • bash .github/scripts/release-oci-artifacts_test.sh (14 tests, including missing and malformed image attestations)
  • bash .github/scripts/release-parity-manifest_test.sh
  • node --test .github/scripts/release-assets_test.mjs (15 tests)
  • Full affected release suite, tooling tests, Make graph, ShellCheck, actionlint, Prettier, markdownlint, and Markdown table checks pass.
  • The installer downloaded Syft v1.51.1 and verified all four pinned archive hashes against the upstream checksum file.

The image-attestation path is covered locally with deterministic Buildx fixtures. A real registry publication remains the draft exit criterion above.

File change summary

File Summary of change
.goreleaser.yaml Generate deterministic CLI SPDX assets and enable production-image SBOM attestations while isolating SBOMs from binary checksums.
build/tools.yaml, build/tools.generated.mk, build/tools.mk, build/scripts/install-syft.sh Pin and checksum-verify Syft v1.51.1 on Linux and macOS for amd64 and arm64.
.github/workflows/{goreleaser-snapshot,build-release}.yaml Install Syft, retain generated documents, and gate draft, finalization, and published reconciliation paths on SBOM verification.
.github/scripts/{verify-goreleaser-snapshot,release-assets,release-oci-artifacts,release-parity-manifest}* Validate local and remote SPDX documents, per-platform image attestations, exact asset sets, checksum isolation, and parity classification.
.github/scripts/release-sboms_test.sh, build/test.mk Add a focused SBOM contract suite to the repository test graph.
docs/contributing/contributing-releases/README.md Document SBOM formats, names, locations, and image-attestation inspection.
eng/design-notes/tools/2026-09-goreleaser-stack-review/pr-14-goreleaser-sboms.md Review note for this layer: what changed in review, why, the value, and the impact

@github-actions

Copy link
Copy Markdown

Dependency Review

✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.

Scanned Files

None

@github-actions

github-actions Bot commented Aug 28, 2026

Copy link
Copy Markdown

Unit Tests

    2 files  +    2    459 suites  +459   9m 16s ⏱️ + 9m 16s
6 627 tests +6 627  6 625 ✅ +6 625  2 💤 +2  0 ❌ ±0 
7 935 runs  +7 935  7 933 ✅ +7 933  2 💤 +2  0 ❌ ±0 

Results for commit 38af438. ± Comparison against base commit 6fe2889.

♻️ This comment has been updated with latest results.

@codecov

codecov Bot commented Aug 28, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
⚠️ Please upload report for BASE (dp/goreleaser-tag-cutover@6fe2889). Learn more about missing BASE report.

Additional details and impacted files
@@                     Coverage Diff                      @@
##             dp/goreleaser-tag-cutover   #12869   +/-   ##
============================================================
  Coverage                             ?   59.51%           
============================================================
  Files                                ?      772           
  Lines                                ?    45053           
  Branches                             ?        0           
============================================================
  Hits                                 ?    26815           
  Misses                               ?    18238           
  Partials                             ?        0           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@github-actions

github-actions Bot commented Aug 28, 2026

Copy link
Copy Markdown

Functional Tests - upgrade-noncloud

1 tests   0 ✅  5m 4s ⏱️
1 suites  0 💤
1 files    1 ❌

For more details on these failures, see this check.

Results for commit 38af438.

♻️ This comment has been updated with latest results.

@DariuszPorowski
DariuszPorowski force-pushed the dp/goreleaser-sboms branch 3 times, most recently from a04b9ae to 798f05c Compare August 28, 2026 20:17
@DariuszPorowski DariuszPorowski changed the title feat: publish release SBOMs feat(refactor-release): publish release SBOMs Aug 28, 2026
@github-actions

github-actions Bot commented Sep 3, 2026

Copy link
Copy Markdown

Functional Tests - cli-noncloud

48 tests  ±0   48 ✅ ±0   11m 39s ⏱️ +16s
 1 suites ±0    0 💤 ±0 
 1 files   ±0    0 ❌ ±0 

Results for commit 65ee3a7. ± Comparison against base commit 158a1a4.

♻️ This comment has been updated with latest results.

@github-actions

github-actions Bot commented Sep 3, 2026

Copy link
Copy Markdown

Functional Tests - corerp-noncloud

190 tests  ±0   188 ✅ ±0   1h 14m 16s ⏱️ + 2m 8s
  3 suites ±0     2 💤 ±0 
  1 files   ±0     0 ❌ ±0 

Results for commit 65ee3a7. ± Comparison against base commit 158a1a4.

♻️ This comment has been updated with latest results.

@github-actions

github-actions Bot commented Sep 3, 2026

Copy link
Copy Markdown

Functional Tests - corerp-cloud

32 tests  ±0   31 ✅ ±0   21m 44s ⏱️ + 2m 28s
 2 suites ±0    1 💤 ±0 
 1 files   ±0    0 ❌ ±0 

Results for commit 65ee3a7. ± Comparison against base commit 158a1a4.

♻️ This comment has been updated with latest results.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

The release gates accept schema-invalid SPDX documents, and the claimed deterministic output is not currently produced.

Once you've addressed the issues Copilot identified, you can request another Copilot review.

Pull request overview

Adds SPDX SBOM generation and release verification for CLI binaries and production images.

Changes:

  • Configures Syft and GoReleaser SBOM generation.
  • Adds release gates and contract tests for SBOM assets and attestations.
  • Documents SBOM discovery and inspection.
File summaries
File Description
.cspellignore Allows the Anchore name.
.goreleaser.yaml Configures CLI and image SBOMs.
.github/scripts/release-assets.mjs Verifies published CLI SBOMs.
.github/scripts/release-assets_test.mjs Tests release SBOM verification.
.github/scripts/release-oci-artifacts.sh Verifies image attestations.
.github/scripts/release-oci-artifacts_test.sh Tests image SBOM validation.
.github/scripts/release-parity-manifest.sh Permits expected SBOM assets.
.github/scripts/release-parity-manifest_test.sh Tests parity classification.
.github/scripts/release-sboms_test.sh Adds SBOM contract tests.
.github/scripts/verify-goreleaser-snapshot.sh Validates generated SBOM output.
.github/workflows/build-release.yaml Gates releases on SBOM checks.
.github/workflows/goreleaser-snapshot.yaml Installs Syft and retains SBOMs.
build/scripts/install-syft.sh Installs checksum-verified Syft.
build/test.mk Adds SBOM tests to the test graph.
build/tools.generated.mk Defines generated Syft pins.
build/tools.mk Adds the Syft installation target.
build/tools.yaml Pins Syft release artifacts.
docs/contributing/contributing-releases/README.md Documents release SBOM usage.
Review details
  • Files reviewed: 18/18 changed files
  • Comments generated: 4
  • Review effort level: Balanced

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment on lines +78 to +90
typeof document !== "object" ||
document === null ||
!/^SPDX-2\.\d+$/.test(document.spdxVersion) ||
document.SPDXID !== "SPDXRef-DOCUMENT" ||
document.dataLicense !== "CC0-1.0" ||
typeof document.documentNamespace !== "string" ||
!document.documentNamespace.startsWith("https://") ||
typeof document.creationInfo?.created !== "string" ||
!Array.isArray(creators) ||
!creators.some((creator) => /^Tool: syft-/.test(creator)) ||
!Array.isArray(document.packages) ||
document.packages.length === 0 ||
!Array.isArray(document.relationships)
Comment on lines +695 to +707
| ($document | type == "object")
and ($document.spdxVersion
| type == "string" and test("^SPDX-2\\.[0-9]+$"))
and $document.SPDXID == "SPDXRef-DOCUMENT"
and $document.dataLicense == "CC0-1.0"
and ($document.documentNamespace
| type == "string" and startswith("https://"))
and ($document.creationInfo.created
| type == "string" and length > 0)
and any($document.creationInfo.creators[]?;
startswith("Tool: syft-"))
and ($document.packages | type == "array" and length > 0)
and ($document.relationships | type == "array")
Comment on lines +100 to +112
jq -e '
type == "object"
and (.spdxVersion
| type == "string" and test("^SPDX-2\\.[0-9]+$"))
and .SPDXID == "SPDXRef-DOCUMENT"
and .dataLicense == "CC0-1.0"
and (.documentNamespace
| type == "string" and startswith("https://"))
and (.creationInfo.created | type == "string" and length > 0)
and any(.creationInfo.creators[]?; startswith("Tool: syft-"))
and (.packages | type == "array" and length > 0)
and (.relationships | type == "array")
' "${file}" >/dev/null || fail "invalid SPDX JSON SBOM: ${file}"
Comment thread .goreleaser.yaml
Comment on lines +118 to +123
args:
- "${artifact}"
- --output
- "spdx-json=${document}"
- --enrich
- golang
@DariuszPorowski
DariuszPorowski removed this pull request from stack #12738 September 17, 2026 21:54
@DariuszPorowski
DariuszPorowski added this pull request to stack #13045 September 17, 2026 21:56
@DariuszPorowski
DariuszPorowski removed this pull request from stack #13045 September 18, 2026 20:12
@DariuszPorowski
DariuszPorowski added this pull request to stack #13056 September 18, 2026 20:12
@DariuszPorowski
DariuszPorowski force-pushed the dp/goreleaser-sboms branch 3 times, most recently from ee1f481 to 9c88914 Compare September 18, 2026 22:04
@DariuszPorowski
DariuszPorowski removed this pull request from stack #13056 September 18, 2026 22:57
@DariuszPorowski
DariuszPorowski added this pull request to stack #13058 September 18, 2026 22:59
@DariuszPorowski
DariuszPorowski removed this pull request from stack #13058 September 18, 2026 23:05
@DariuszPorowski
DariuszPorowski added this pull request to stack #13060 September 18, 2026 23:06
@DariuszPorowski
DariuszPorowski removed this pull request from stack #13060 September 19, 2026 02:21
@DariuszPorowski
DariuszPorowski added this pull request to stack #13063 September 19, 2026 02:21
Generate SPDX JSON SBOMs for every raw rad binary with a pinned,
checksum-verified Syft release, and publish them as additive GitHub
Release assets without changing the existing binary checksum contract.

Enable BuildKit SBOM attestations on every GoReleaser production image
and require one valid SPDX document for each locked platform before
finalization. Recheck CLI and image SBOMs when reconciling an already
published release.

Classify the seven CLI SBOM files as intentional parity additions,
retain them with GoReleaser workflow metadata, and document how to find
both release assets and per-platform image attestations.

Refs: #12818
Signed-off-by: Dariusz Porowski <3431813+DariuszPorowski@users.noreply.github.com>
…on review notes

Signed-off-by: Dariusz Porowski <3431813+DariuszPorowski@users.noreply.github.com>
@radius-functional-tests

radius-functional-tests Bot commented Sep 19, 2026

Copy link
Copy Markdown

Radius functional test overview

🔍 Go to test action run

Click here to see the test run details
Name Value
Repository radius-project/radius
Commit ref 38af438
Unique ID funce0b5eb1cb2
Image tag pr-funce0b5eb1cb2
  • Dapr: 1.14.4
  • Azure KeyVault CSI driver: 1.4.2
  • Azure Workload identity webhook: 1.3.0
  • Bicep recipe location ghcr.io/radius-project/dev/test/testrecipes/test-bicep-recipes/<name>:pr-funce0b5eb1cb2
  • Terraform recipe location http://tf-module-server.radius-test-tf-module-server.svc.cluster.local/<name>.zip (in cluster)
  • applications-rp test image location: ghcr.io/radius-project/dev/applications-rp:pr-funce0b5eb1cb2
  • dynamic-rp test image location: ghcr.io/radius-project/dev/dynamic-rp:pr-funce0b5eb1cb2
  • controller test image location: ghcr.io/radius-project/dev/controller:pr-funce0b5eb1cb2
  • ucp test image location: ghcr.io/radius-project/dev/ucpd:pr-funce0b5eb1cb2
  • deployment-engine test image location: ghcr.io/radius-project/deployment-engine:latest

Test Status

⌛ Building Radius and pushing container images for functional tests...
✅ Container images build succeeded
⌛ Publishing Bicep Recipes for functional tests...
✅ Recipe publishing succeeded
⌛ Starting corerp-cloud functional tests...
⌛ Starting ucp-cloud functional tests...
✅ ucp-cloud functional tests succeeded
✅ corerp-cloud functional tests succeeded

@DariuszPorowski
DariuszPorowski removed this pull request from stack #13063 September 21, 2026 16:26
@DariuszPorowski
DariuszPorowski added this pull request to stack #13074 September 21, 2026 16:26

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Generate release SBOMs

2 participants