Skip to content

ci(feat): split release workflow into independent node, toolkit, and runtime components#1261

Merged
NachoPal merged 20 commits into
mainfrom
nacho/split-releases-by-component
Apr 10, 2026
Merged

ci(feat): split release workflow into independent node, toolkit, and runtime components#1261
NachoPal merged 20 commits into
mainfrom
nacho/split-releases-by-component

Conversation

@NachoPal

@NachoPal NachoPal commented Apr 8, 2026

Copy link
Copy Markdown
Contributor

Overview

Replace the single node-only boolean in the release workflow with three independent skip flags (skip-node, skip-toolkit, skip-runtime) so any combination of components can be released independently.

Key changes

  • Separate versioning: Toolkit images are tagged with the toolkit version from util/toolkit/Cargo.toml; runtime releases use spec_version from runtime/src/lib.rs (e.g. 001_000_0001.0.0)
  • Dynamic git tags: Concatenated from included components with suffix at the end (e.g. node-1.0.0-toolkit-1.0.0-runtime-1.0.0-rc.1)
  • Per-component release notes: changes/ restructured into node/, toolkit/, and runtime/ subdirectories; skipped component dirs are removed before season build so only relevant sections render
  • Per-component archiving: archive-changes and reset-changes run once per included component instead of a single call
  • Per-component version bump: "Bump components version on main" now bumps node (Cargo.toml), toolkit (Cargo.toml), and runtime (spec_version) independently based on skip flags
  • Release notes header: Root index.md renders Git tag + Components section with icons (📦 Node, 🧰 Toolkit, ⚙️ Runtime); component sections include Docker Images where applicable
  • Security fix: ${{ inputs.* }} expressions moved from run: blocks to env: to prevent shell injection

🗹 TODO before merging

  • Ready

📌 Submission Checklist

  • Changes are backward-compatible (or flagged if breaking)
  • Pull request description explains why the change is needed
  • Self-reviewed the diff
  • I have included a change file, or skipped for this reason: change only affects CI/release workflow
  • If the changes introduce a new feature, I have bumped the node minor version
  • Update documentation (if relevant)
  • Updated AGENTS.md if build commands, architecture, or workflows changed
  • No new todos introduced

🧪 Testing Evidence

  • YAML validated with python3 -c "import yaml; yaml.safe_load(open(...))" — passes
  • Manually traced all 7 release scenarios through the workflow:
    • Full release (default): all jobs run, node uses node version, toolkit uses toolkit version
    • Toolkit-only (skip-node + skip-runtime): only toolkit image/SBOM/asset jobs run, git tag = toolkit-X.Y.Z, release notes from changes/toolkit/
    • Node-only (skip-toolkit + skip-runtime): only node image/SBOM/asset jobs run
    • Runtime-only (skip-node + skip-toolkit): only srtool WASM build runs, no archive PR
    • All-three-skipped: rejected by validate-inputs job
  • Verified !cancelled() && !failure() pattern correctly allows downstream jobs when upstream SBOM jobs are skipped
  • Verified inputs.skip-X != true (step-level) vs github.event.inputs.skip-X != 'true' (job-level for reusable workflows) context rules

Please describe any additional testing aside from CI:

  • Additional tests are provided (if possible)

🔱 Fork Strategy

  • Node Runtime Update
  • Node Client Update
  • Other: CI/release workflow only — no runtime or client changes
  • N/A

Links

@NachoPal NachoPal requested a review from a team as a code owner April 8, 2026 11:12
Comment thread .github/workflows/release-image.yml Fixed
@gilescope

Copy link
Copy Markdown
Contributor

will need a changelog entry to point out to people that versioning is changing for toolkit.

@NachoPal NachoPal marked this pull request as draft April 9, 2026 09:08
@NachoPal NachoPal marked this pull request as ready for review April 9, 2026 17:16
@NachoPal NachoPal enabled auto-merge (squash) April 9, 2026 18:18
@NachoPal NachoPal disabled auto-merge April 9, 2026 18:18

@ozgb ozgb 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.

If you haven't already, it would be good to create a -test pre-release with this workflow to verify it's working and see what the output looks like

Comment thread .github/workflows/release-image.yml
Comment thread AGENTS.md
@NachoPal

Copy link
Copy Markdown
Contributor Author

If you haven't already, it would be good to create a -test pre-release with this workflow to verify it's working and see what the output looks like

Yep, I did multiple times until I got the expected result :) I left a draft release as sample if you wanna check

@ozgb

ozgb commented Apr 10, 2026

Copy link
Copy Markdown
Contributor

If you haven't already, it would be good to create a -test pre-release with this workflow to verify it's working and see what the output looks like

Yep, I did multiple times until I got the expected result :) I left a draft release as sample if you wanna check

Looks great!

One thing I noticed, runtime asset is the only one not versioned:
image

That's always been the case, but could be good to fix that in this PR too

@NachoPal NachoPal enabled auto-merge April 10, 2026 15:01

@ozgb ozgb 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.

LGTM

One minor nit: in draft mode, the full git tag doesn't get created - this is a feature of gh/draft releases - but, the individual tags do get created

Solution is to either:

  1. Create all tags for all release types, including draft
  2. Skip creating git tags for each component when in draft mode

I have a slight preference for option 2 as it follows github conventions more closely, but I don't mind which

@NachoPal NachoPal added this pull request to the merge queue Apr 10, 2026
Merged via the queue into main with commit 034a558 Apr 10, 2026
62 checks passed
@NachoPal NachoPal deleted the nacho/split-releases-by-component branch April 10, 2026 16:56
m2ux added a commit that referenced this pull request Apr 23, 2026
…runtime components (#1261)

* feat: split releases

* chore: change file

* fix: interpolation

* fix(ci): gate archive-changes steps on archive-changes input

* feat: add runtime change folder

* fix: loop over release types for handling change files

* fix: release template

* fix: template nit

* fix: reorder releases component sections

* fix: bump all components version

* fix: runtime archive

* fix reordering

* fix: undo component reorder

* fix: review feedback

* temporary fix to test release

* fix: revert

* fix: npm audit

* fix: gh api call

* fix: gh api call 2
Signed-off-by: Mike Clay <mike.clay@shielded.io>
m2ux added a commit that referenced this pull request Apr 23, 2026
…runtime components (#1261)

* feat: split releases

* chore: change file

* fix: interpolation

* fix(ci): gate archive-changes steps on archive-changes input

* feat: add runtime change folder

* fix: loop over release types for handling change files

* fix: release template

* fix: template nit

* fix: reorder releases component sections

* fix: bump all components version

* fix: runtime archive

* fix reordering

* fix: undo component reorder

* fix: review feedback

* temporary fix to test release

* fix: revert

* fix: npm audit

* fix: gh api call

* fix: gh api call 2
Signed-off-by: Mike Clay <mike.clay@shielded.io>
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.

5 participants