Skip to content

fix: use immutableCreate to fix missing SPDX/intoto release assets#1129

Merged
pethers merged 3 commits intomasterfrom
copilot/fix-missing-spdx-intoto-assets
Mar 20, 2026
Merged

fix: use immutableCreate to fix missing SPDX/intoto release assets#1129
pethers merged 3 commits intomasterfrom
copilot/fix-missing-spdx-intoto-assets

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Mar 20, 2026

Release assets (SPDX SBOM, intoto attestations, zip) were silently not being uploaded. The CI logs showed:

##[warning]Failed to upload artifact homepage-v1.0.4.zip. Cannot upload assets to an immutable release.
##[warning]Failed to upload artifact homepage-v1.0.4.spdx.json. Cannot upload assets to an immutable release.

ncipollo/release-action with makeLatest: true creates the release first (immutable), then tries to upload artifacts in a separate API call — which the immutable release rejects. The step still reports success.

Fix

  • makeLatest: trueimmutableCreate: true — creates the immutable release with artifacts atomically in one operation, matching the working riksdagsmonitor pattern
  • Added artifact verification step — fails fast with explicit error if any of the 5 expected files are missing before release creation
  • Added sha256 checksum — generates homepage-vX.Y.Z.zip.sha256 and includes it in release assets (parity with riksdagsmonitor)
  • Enhanced release body — documents artifacts and includes verification commands (sha256sum -c, gh attestation verify)

💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

…to assets

Root cause: ncipollo/release-action with makeLatest created releases as
immutable, then failed to upload artifacts in a separate API call with
"Cannot upload assets to an immutable release".

Fix: Replace makeLatest with immutableCreate to create immutable releases
WITH artifacts atomically (matching riksdagsmonitor pattern).

Changes:
- Replace makeLatest: true with immutableCreate: true in ncipollo/release-action
- Add sha256 checksum generation for release ZIP verification
- Add artifact verification step before release creation
- Include sha256 file in release artifacts
- Enhance release body with artifact documentation and verification commands

Co-authored-by: pethers <1726836+pethers@users.noreply.github.com>
@github-actions github-actions bot added infrastructure CI/CD and infrastructure content-pages Main website pages labels Mar 20, 2026
Co-authored-by: pethers <1726836+pethers@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix missing spdx and intoto assets in release workflow fix: use immutableCreate to fix missing SPDX/intoto release assets Mar 20, 2026
Copilot AI requested a review from pethers March 20, 2026 12:47
@sonarqubecloud
Copy link
Copy Markdown

@pethers pethers marked this pull request as ready for review March 20, 2026 12:51
@pethers pethers requested a review from Copilot March 20, 2026 12:52
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR updates the GitHub Actions release workflow to ensure all expected supply-chain artifacts (zip, checksum, SPDX SBOM, and in-toto attestations) are actually uploaded to the GitHub Release, addressing prior silent asset upload failures when creating immutable releases.

Changes:

  • Generate and publish a sha256 checksum file for the release zip.
  • Add a pre-release verification step that fails the workflow if any expected artifacts are missing.
  • Switch ncipollo/release-action from makeLatest: true to immutableCreate: true, and enhance the release body with artifact verification commands.

@pethers pethers merged commit 1b4bd08 into master Mar 20, 2026
17 of 18 checks passed
@pethers pethers deleted the copilot/fix-missing-spdx-intoto-assets branch March 20, 2026 12:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

content-pages Main website pages infrastructure CI/CD and infrastructure size/M

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants