Skip to content

[OPS-1301] Use baton-ci app token in capabilities_and_config.yaml - #90

Closed
ennyjfrick wants to merge 1 commit into
mainfrom
ennyfrick/ops-1301-baton-ci-migration
Closed

[OPS-1301] Use baton-ci app token in capabilities_and_config.yaml#90
ennyjfrick wants to merge 1 commit into
mainfrom
ennyfrick/ops-1301-baton-ci-migration

Conversation

@ennyjfrick

Copy link
Copy Markdown
Contributor

Replace the long-lived RELENG_GITHUB_TOKEN PAT with a short-lived baton-ci app token scoped to the current repo.

Mirrors the OPS-1300 templated workflow pattern. With the Connector Rules ruleset hardened, the legacy PAT only continues to work because of the temp org-admin mitigation; this PR replaces it with the proper App-token bypass actor before that mitigation is removed.

Linear: OPS-1301

🤖 Generated with Claude Code

Replace the long-lived RELENG_GITHUB_TOKEN PAT with a short-lived
baton-ci app token scoped to the current repo. Mirrors the OPS-1300
templated workflow pattern; needed before the temp org-admin
mitigation can safely be removed.

Linear: https://linear.app/ductone/issue/OPS-1301

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@ennyjfrick
ennyjfrick requested a review from a team April 30, 2026 16:04
@linear

linear Bot commented Apr 30, 2026

Copy link
Copy Markdown

@github-actions

github-actions Bot commented Apr 30, 2026

Copy link
Copy Markdown
Contributor

Claude finished @ennyjfrick's task in 45s —— View job


PR Review: [OPS-1301] Use baton-ci app token in capabilities_and_config.yaml

  • Gather context and read changed files
  • Review the changes
  • Post review feedback

LGTM — clean, minimal change that does exactly what it says.

What changed

The workflow replaces the long-lived RELENG_GITHUB_TOKEN PAT with a short-lived, repo-scoped token minted via the baton-ci GitHub App (actions/create-github-app-token@v2). The minted token is used for actions/checkout, and since checkout persists credentials, the downstream EndBug/add-and-commit step will inherit it for push operations. This is the correct pattern.

Review

Token scoping — The token is properly scoped to owner + the current repository name via github.event.repository.name. This is the minimum scope needed for checkout + commit-and-push. Looks good.

Step ordering — The token mint step is placed before checkout, which is correct since the checkout step depends on the token output.

Action versionactions/create-github-app-token@v2 is the current stable version. Consider pinning to a full SHA for supply-chain hardening (e.g., actions/create-github-app-token@<sha>), though this is a minor nit and may not match the repo's conventions.

Note

RELENG_GITHUB_TOKEN is still referenced in two other workflows:

  • .github/workflows/verify.yaml
  • .github/workflows/release.yaml

These are presumably tracked under separate tickets (OPS-1300 templated workflow pattern), but worth confirming they're on the migration roadmap.

No issues found — this is ready to merge.

@ennyjfrick

Copy link
Copy Markdown
Contributor Author

Closing — generate-baton-metadata.yaml already exists in this repo (the modern baton-admin-managed equivalent), so this legacy capabilities_and_config.yaml is a duplicate and should be deleted instead. Replacing with a deletion PR.

@ennyjfrick ennyjfrick closed this Apr 30, 2026
@ennyjfrick
ennyjfrick deleted the ennyfrick/ops-1301-baton-ci-migration branch April 30, 2026 16:41
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