Repository navigation
Conversation
Superseded — see the current review report for commit
|
| GOSUMDB: sum.golang.org | ||
| permissions: | ||
| contents: read | ||
| contents: write # Create/upload the caller repository's GitHub release assets. |
There was a problem hiding this comment.
🟡 Suggestion (medium confidence): If a caller grants only contents: read, for example through a read-only org default, GitHub rejects the whole called workflow at startup. The error is "nested job is requesting 'contents: write'", so this is not limited to the binaries job, and it affects every caller that tracks this ref as soon as it merges. The PR body covers this, but the guard is only prose. Consider merging only after the caller-template PR lands, or tagging this as a breaking release so callers that pin a ref opt in.
Superseded — see the current review report for commit
|
a69c046 to
86bc9b9
Compare
Superseded — see the current review report for commit
|
| run: goreleaser release --clean --config ../_workflows/_generated/.goreleaser.binaries.yaml | ||
| env: | ||
| GITHUB_TOKEN: ${{ secrets.RELENG_GITHUB_TOKEN }} | ||
| GITHUB_TOKEN: ${{ github.token }} |
There was a problem hiding this comment.
🟡 Suggestion (low-medium confidence): For plain tag pushes, release-preflight reports prerelease=absent and GoReleaser creates the GitHub Release itself. A release created with github.token does not fire release: events, so any caller workflow listening for release: [published|created] silently stops running (it did fire when the release was made with the PAT). Please add this to the caller inventory and docs, or check that no caller depends on it.
Superseded — see the current review report for commit
|
86bc9b9 to
2828b7b
Compare
Superseded — see the current review report for commit
|
Superseded — see the current review report for commit
|
2828b7b to
95fa790
Compare
Superseded — see the current review report for commit
|
General PR Review: Use caller-scoped job token for release assetsBlocking Issues: 0 | Suggestions: 1 | Threads Resolved: 0 Review SummaryThe four GoReleaser steps in What I checked:
Coverage gap: I did not run a live release. Asset upload with the job token and the Homebrew tap write are still untested. The PR description says the same. Security IssuesNone found. The change reduces privilege: the org-wide token moves out of GoReleaser, and the new write grant is limited to the caller repository and one job. Correctness IssuesNone found. Suggestions
Prompt for AI agentsReviewed commit: |
Superseded — see the current review report for commit
|
Superseded — see the current review report for commit
|
95fa790 to
fc53831
Compare
Superseded — see the current review report for commit
|
Superseded — see the current review report for commit
|
fc53831 to
49fe773
Compare
Superseded — see the current review report for commit
|
Superseded — see the current review report for commit
|
49fe773 to
573bbc4
Compare
Superseded — see the current review report for commit
|
Superseded — see the current review report for commit
|
573bbc4 to
4ac2166
Compare
Superseded — see the current review report for commit
|
Superseded — see the current review report for commit
|
Co-authored-by: c1-squire-dev[bot] <c1-squire-dev[bot]@users.noreply.github.com>
Co-authored-by: c1-squire-dev[bot] <c1-squire-dev[bot]@users.noreply.github.com>
4ac2166 to
99f172e
Compare
Superseded — see the current review report for commit
|
General PR Review: Use caller-scoped job token for release assetsBlocking Issues: 0 | Suggestions: 1 | Threads Resolved: 0 Review SummaryAll four I scanned the full PR diff for security and correctness issues. The token wiring checks out:
No repo-local criteria loaded, because the PR's base is not the default branch. Only the base criteria were applied. Security IssuesNone found. Correctness IssuesNone found. Suggestions
Resolved prior findings
Prompt for AI agentsReviewed commit: |
Stack: stacked on #166; merges after it.
Why
Stop giving GoReleaser an organization-wide release token when it only needs the caller repository's job token.
What
github.token.contents: writeonly togoreleaser-binaries, the sole job whose GoReleaser configuration enables GitHub Release creation/upload. Windows, Docker OCI and Lambda configurations disable GitHub Release publication and keepcontents: read.Caller inventory and rollout dependency
DO NOT roll out before caller permissions are inventoried and explicitly granted where needed. A callee cannot elevate a read-only caller grant. The public Go caller template and available rendered examples declare no explicit permissions block, so effective fleet defaults are unverified, not known-broken. The required caller release-job grant is
contents: writeplusid-token: writefor the existing signing/publishing path, retainingactions: readandchecks: readfor workflow-run and failure-annotation reads. Do not broaden unrelated caller jobs. Releases GoReleaser creates with the job token do not trigger calleron: releaseworkflows; inventory callers for such workflows as part of the rollout.Named rollout dependency: https://github.com/ConductorOne/baton-admin/pull/1016 explicitly grants the caller release job
contents: write,id-token: write,actions: readandchecks: read. Render/update callers from that change before promoting this token switch. This PR intentionally does not modify caller repositories.Evidence
make test-scripts: PASS after updating the deliberately changed bootstrap permission assertion (native PowerShell fixture skipped because PowerShell is unavailable).make workflow-validate: PASS.git diff --check: PASS.contents: readcontract; the assertion now expects write only for that publisher and the complete suite was rerun.Limits and handoff
Draft only. Live canary asset upload, Homebrew delivery and the deliberately read-only upload negative control were not run. Complete them after the caller grant prerequisite.
contents: writeis repository-scoped but not asset-only: it can modify contents and tags while the job token is valid.The deferred tap leg needs a short-lived
HOMEBREW_TAP_TOKENscoped toconductorone/homebrew-batonwithcontents: writeonly, plus administrator-owned rotation. Until then, the secret declaration and onePublish Homebrew formulause ofRELENG_GITHUB_TOKENare the only residuals.Live evidence (2026-10-22)
fc53831c, includes Pin privileged release actions and document custody #166);goreleaser-binariespublished 5 release assets via the jobGITHUB_TOKENunder the caller'scontents:writegrant.