Skip to content

fix(ci): release with GITHUB_TOKEN instead of an expired PAT - #289

Closed
mcaulifn wants to merge 1 commit into
mainfrom
fix-release-token
Closed

mcaulifn wants to merge 1 commit into
mainfrom
fix-release-token

Conversation

@mcaulifn

@mcaulifn mcaulifn commented Dec 2, 2026

Copy link
Copy Markdown
Member

Why

The Release workflow runs semantic-release with secrets.GH_PERSONAL_ACCESS_TOKEN. That token no longer works: every Release run on main on 2026-12-02 failed, and github-ip-ranges.yaml, which uses the same secret, has failed since 2026-11-22 (last green 2026-11-15).

What changed

.github/workflows/release.yaml only:

  • semantic-release uses secrets.GITHUB_TOKEN, and the job has contents, issues and pull-requests write permissions.
  • publish.yaml runs on release: published, and a release created with GITHUB_TOKEN does not trigger other workflows. So the release job now builds the Lambda zip (the same Build, Inject Mozilla Cert Bundles and Zip Lambda steps as publish.yaml) before semantic-release, and @semantic-release/github uploads proxy-lambda.zip as the asset already listed in .releaserc.yaml.
  • The job exposes new_release_published and new_release_git_tag as outputs.

Checked

  • .releaserc.yaml has only commit-analyzer, release-notes-generator and @semantic-release/github, so nothing pushes a commit to main. The main ruleset has no restriction that blocks GITHUB_TOKEN from creating the tag and release.
  • YAML parses and actionlint is clean for this file.
  • Not run: the build steps locally. They are copied from publish.yaml.

Notes

  • The build now runs on every push to main, including pushes that produce no release, and a build failure blocks the release.
  • publish.yaml is unchanged, so manually editing or publishing a release still triggers it.
  • github-ip-ranges.yaml still uses the old secret and is not changed here.

🤖 Generated with Claude Code

The Release workflow authenticated semantic-release with a personal access
token that has expired, so every release run on main fails. Switch it to the
built-in GITHUB_TOKEN and grant the job the contents, issues and pull-requests
write permissions semantic-release needs.

A release created with GITHUB_TOKEN does not trigger other workflows, so
publish.yaml would no longer attach proxy-lambda.zip to new releases. The
release job now builds the Lambda zip before running semantic-release, and
@semantic-release/github uploads it as the release asset already configured in
.releaserc.yaml. The job also exposes new_release_published and
new_release_git_tag as outputs.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@mcaulifn
mcaulifn requested a review from a team as a code owner December 2, 2026 14:49
@mcaulifn

mcaulifn commented Dec 2, 2026

Copy link
Copy Markdown
Member Author

Closing in favour of #290 — the release route moves to release-please.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant