Skip to content

chore: upgrade actions to Node 24 runtime and enforce SHA pinning - #261

Merged
John C. Bland II (johncblandii) merged 4 commits into
mainfrom
chore/node24-runtime-upgrade
Aug 13, 2026
Merged

chore: upgrade actions to Node 24 runtime and enforce SHA pinning#261
John C. Bland II (johncblandii) merged 4 commits into
mainfrom
chore/node24-runtime-upgrade

Conversation

@johncblandii

@johncblandiiJohn C. Bland II (johncblandii) commented Aug 12, 2026

Copy link
Copy Markdown
Contributor

what

  • Bump GitHub Actions references in the shared workflows to versions running on the Node 24 runtime:
    • actions/checkout@v4/@v6v7.0.1
    • actions/create-github-app-token@v1 / @v2v3.2.0
    • actions/github-script@v7v9.0.0
    • actions/setup-go@v5v7.0.0
    • actions/setup-node@v4v7.0.0
    • aws-actions/configure-aws-credentials@v4v6.2.3
    • cloudposse-github-actions/get-pr@v2v3.1.0
    • crazy-max/ghaction-import-gpg@v6v7.0.0
    • goreleaser/goreleaser-action@v5v7.2.3
    • hashicorp/setup-terraform@v3v4.0.1
    • peter-evans/create-or-update-comment@v4v5.0.0
    • robherley/go-test-action@v0v1.1.0
    • stefanzweifel/git-auto-commit-action@v5v7.2.0
  • One input fix required by a breaking change: aws-actions/configure-aws-credentials v5+ rejects
    non-YAML-1.2 booleans (throws instead of coercing), so mask-aws-account-id: "no" in
    shared-terraform-chatops.yml is now "false".
  • SHA-pin every third-party action reference (owner/repo@<sha> # vX.Y.Z), and add a
    verify-sha-pinning workflow + composite action (adapted from
    cloudposse/atmos)
    that enforces it on PRs and weekly via cron:
    • Coverage — fails if any third-party uses: ref is not SHA-pinned
    • Drift — fails if a pinned SHA no longer matches the tag named in its version comment
      (catches force-pushed tags / supply-chain tampering)
    • References to this repo's own shared-*.yml@main reusable workflows are exempt — distributing
      at @main is this repository's core model, for this repo's own workflows as much as for the
      181 downstream repos
    • Un-taggable refs are SHA-pinned to their current branch head with a # main comment
      (cloudposse-github-actions/screenshot, mpoc/nexus-validate-using-remote-schema-action)
  • Every new ref was verified two ways: runs.using: node24 (or composite/docker) at the pinned ref,
    and pinned SHA == the peeled commit of the version tag in its comment (64 tag-verified,
    0 mismatches, 0 unpinned). Release notes for each major bump were reviewed; all other inputs in
    use are unchanged.

why

  • GitHub is deprecating the Node 20 runtime; affected workflows emit a deprecation warning and are
    already being force-migrated to Node 24
  • Pinning explicitly to Node 24 releases makes the migration deliberate rather than implicit
  • These shared workflows are consumed via @main by ~181 downstream cloudposse/* repos, so this
    single change clears the warning across most of the org — and SHA pinning means a compromised or
    force-pushed upstream tag can no longer silently change what runs in every consumer's CI
  • Renovate keeps SHA pins current the same way it does tag pins (it updates the SHA and the comment)

references

still on Node 20 (or older)

@johncblandiiJohn C. Bland II (johncblandii) added the no-release Do not create a new release (wait for additional code changes) label Aug 12, 2026
CopilotAI lite review requested due to automatic review settings August 12, 2026 20:19
@johncblandiiJohn C. Bland II (johncblandii) added the no-release Do not create a new release (wait for additional code changes) label Aug 12, 2026
kevcube
Kevin (kevcube) previously approved these changes Aug 12, 2026

@kevcubeKevin (kevcube) left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

lgtm. only non-standard change is shared-terraform-chatops.yml:314.
i'd unquote the bool but it doesn't matter.

CopilotAI 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.

Pull request overview

Updates shared GitHub Actions workflows to use newer major versions that run on the Node 24 runtime (to avoid Node 20 deprecation warnings across downstream consumers).

Changes:

  • Bumped multiple commonly used actions (checkout, github-script, setup-go, setup-node, create-github-app-token, configure-aws-credentials, etc.) to Node 24-capable major versions across shared workflows.
  • Applied an input compatibility fix for aws-actions/configure-aws-credentials v5+ boolean parsing (mask-aws-account-id: "false").
  • Updated commit/comment helper actions used by several workflows (e.g., git-auto-commit-action, create-or-update-comment).

Reviewed changes

Copilot reviewed 13 out of 13 changed files in this pull request and generated 1 comment.

Show a summary per file
FileDescription
.github/workflows/shared-terraform-chatops.ymlUpgraded ChatOps workflow action versions (checkout/github-script/setup-go/configure-aws-credentials/etc.) for Node 24 compatibility.
.github/workflows/shared-scheduled-context.ymlBumped checkout to v7 in the scheduled context workflow.
.github/workflows/shared-release-branches.ymlUpgraded create-github-app-token and github-script major versions for Node 24 runtime.
.github/workflows/shared-go-feature-release.ymlUpdated PR/context/comment actions (get-pr, github-script, create-or-update-comment) to newer majors.
.github/workflows/shared-go-auto-release.ymlUpdated release workflow actions (create-github-app-token/checkout/setup-go/import-gpg/goreleaser) to newer majors.
.github/workflows/shared-codeowners.ymlUpdated checkout and create-github-app-token major versions.
.github/workflows/shared-ci-typescript-app-check-dist.ymlUpdated checkout/setup-node/git-auto-commit-action majors for Node 24 runtime.
.github/workflows/shared-ci-terraform.ymlUpdated checkout to v7 and setup-terraform to v4.
.github/workflows/shared-ci-github-action.ymlUpdated checkout to v7 in GitHub Action CI workflow.
.github/workflows/shared-auto-release.ymlUpdated create-github-app-token major; updated commented github-script reference to v9.
.github/workflows/shared-atmos-readme.ymlUpdated create-github-app-token and checkout to newer majors.
.github/workflows/repo-banner.ymlUpdated checkout/github-script/git-auto-commit-action majors for Node 24 runtime.
.github/workflows/org-banner.ymlUpdated checkout and git-auto-commit-action majors for Node 24 runtime.

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

Comment thread.github/workflows/shared-ci-terraform.yml
@mergify

mergifyBot commented Aug 12, 2026

Copy link
Copy Markdown

Important

Cloud Posse Engineering Team Review Required

This pull request modifies files that require Cloud Posse's review. Please be patient, and a core maintainer will review your changes.

To expedite this process, reach out to us on Slack in the #pr-reviews channel.

@mergifymergifyBot added the needs-cloudposse Needs Cloud Posse assistance label Aug 12, 2026
kevcube
Kevin (kevcube) previously approved these changes Aug 12, 2026
Add verify-sha-pinning workflow + composite action (adapted from
cloudposse/atmos) and convert every third-party action reference in
.github/workflows to a SHA pin with a precise version comment.
Same-repo shared-workflow refs stay on @main by design and are
exempted from the check.
@johncblandii

Copy link
Copy Markdown
ContributorAuthor

Added SHA-pin enforcement per request (3b49dba), modeled on atmos's verify-sha-pinning:

  • New .github/workflows/verify-sha-pinning.yml + .github/actions/verify-sha-pinning composite action (PR + weekly cron + manual dispatch) — fails on any unpinned third-party ref and on SHA↔tag drift, with a sticky PR comment on violations.
  • Every third-party uses: ref in this repo is now owner/repo@<sha> # vX.Y.Z with the precise release tag in the comment (major aliases like v7 move on every upstream release and would trip the weekly drift check).
  • One adaptation vs. atmos: refs to this repo's own shared-*.yml@main reusable workflows are exempt — @main distribution is the point of this repo, so pinning self-references would freeze the shared workflows this repo exists to serve.
  • screenshot@main and mpoc/nexus-validate-...@main are SHA-pinned to current branch heads with # main comments (branch-pinned: coverage-checked, not drift-checked).
  • Locally verified with the same parse/resolve logic: 64 tag-verified, 0 mismatches, 0 unpinned, 4 branch-pinned; actionlint clean.

Note for reviewers: Renovate updates SHA pins + comments natively, so routine bumps keep working.

@mergify

mergifyBot commented Aug 13, 2026

Copy link
Copy Markdown

💥 This pull request now has conflicts. Could you fix it John C. Bland II (@johncblandii)? 🙏

@mergifymergifyBot added the conflict This PR has conflicts label Aug 13, 2026
@kevcube

Copy link
Copy Markdown
Member

John C. Bland II (@johncblandii) can you link to the request for sha pinning for posterity?

also this PR is starting to greatly outgrow its title. I think it should merge and additions/improvements can follow after.

@johncblandii

Copy link
Copy Markdown
ContributorAuthor

Kevin (@kevcube) sha pinning was a request by Erik Osterman (Cloud Posse) (@osterman) in chat.

@johncblandiiJohn C. Bland II (johncblandii) changed the title chore: upgrade actions to Node 24 runtimechore: upgrade actions to Node 24 runtime and enforce SHA pinningAug 13, 2026

@kevcubeKevin (kevcube) left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

lgtm.

one note is that dependabot can also do updates of sha-pinned gha workflows and maybe we should depend on that, because it's just bundled with github.

requires a dependabot.yml config and a github actions workflows group, can be a follow-on change.

@johncblandii

Copy link
Copy Markdown
ContributorAuthor

Works for me.

This was referenced Aug 13, 2026
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

no-releaseDo not create a new release (wait for additional code changes)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@johncblandii@kevcube@osterman