fix(ci): grant the reusable workflow the permissions it needs - #18
Merged
Merged
Conversation
The calling job inherited the repository default GITHUB_TOKEN permission, which is read-only. The called workflow needs more: the release job requires contents: write, and in ci.yml the dependency-submission job requires contents: write while the summary job requires pull-requests: write (enable-summary defaults to true). A reusable workflow cannot request more than its caller grants, so GitHub rejected the run while building the job graph - startup_failure, with no jobs and no logs to explain it.
🟡 Code Coverage — 78%284 of 364 lines covered. ℹ️ 38 OTP CVEs auto-ignored (already fixed in running version)These CVEs are patched in the installed OTP version but NVD data
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Adds the
permissions:block the reusableTaure/erlang-ciworkflow needs.Why
Runs were failing with
startup_failure- no jobs, no logs. The calling jobinherited the repository default
GITHUB_TOKENpermission, which isread.The called workflow needs more:
release.yml-> thereleasejob requirescontents: writeci.yml->dependency-submissionrequirescontents: write, andsummaryrequires
pull-requests: write(enable-summarydefaults to true, so thisbites even when it was never opted into)
A reusable workflow cannot request more than its caller grants, so GitHub rejects
the run while building the job graph, before any job exists. That is why there
was nothing to read in the logs.
Taure/kuraand the other green repos already carry this block; these did not.Affects
release.yml. This repo'sci.ymlalready had the block, which is whyCI was green and only Release failed.