Skip to content

fix: pin cascade self-action ref to immutable version tag - #151

Merged
joshua-temple merged 1 commit into
mainfrom
fix/pin-cascade-action-ref
Jun 14, 2026
Merged

joshua-temple merged 1 commit into
mainfrom
fix/pin-cascade-action-ref

Conversation

@joshua-temple

Copy link
Copy Markdown
Collaborator

Problem

The self-action stablekernel/cascade/.github/actions/setup-cli was referenced at the mutable @latest/@master ref by default. A compromise of this action repo would execute in every consumer's CI without any explicit version pinning.

Fix

  • Added DefaultCLIVersion = "v0.1.0" constant in internal/config as the maintained source-of-truth pin (the latest stable tag).
  • GetCLIVersion() now returns DefaultCLIVersion when cli_version is unset or explicitly set to "latest". The "beta" value remains as an explicit, opt-in escape hatch that resolves to @master.
  • All eight generator getCLIRef() methods updated to be consistent with the new default. Explicit version tags (vX.Y.Z) pass through unchanged.
  • Pin is fully overridable via cli_version in the cascade manifest.

Bumping the pin on release

Update DefaultCLIVersion in internal/config/types.go as part of the release process when a new stable tag is created.

Verification

  • Unit tests added/updated: TestGetCLIVersion and TestGetCLIRef_DefaultIsPinnedNotMutable
  • go build ./... && go test ./... - pass
  • cd e2e && go build ./... && go vet ./... - pass
  • golangci-lint run ./... - clean

…ble @latest

Signed-off-by: Joshua Temple <joshua.temple@stablekernel.com>
@joshua-temple
joshua-temple merged commit aacbe43 into main Jun 14, 2026
6 checks passed
@joshua-temple
joshua-temple deleted the fix/pin-cascade-action-ref branch June 14, 2026 02:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant