Skip to content

Commit 90eba40

Browse files
fix(ci): grant callers the permissions their reusable workflows declare (#132)
GitHub refuses these runs at workflow-creation time: `Error calling workflow ... The workflow is requesting '<perm>', but is only allowed '<none>'.` A `workflow_call` job must grant a superset of the callee's declared permissions. This adds the canonical grant (`actions: read`, `contents: read`, `security-events: write`) that the healthy repos already carry.
1 parent b4c601e commit 90eba40

4 files changed

Lines changed: 10 additions & 0 deletions

File tree

‎.github/workflows/governance.yml‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,3 +18,7 @@ permissions:
1818
jobs:
1919
governance:
2020
uses: hyperpolymath/standards/.github/workflows/governance-reusable.yml@fad242d35291de1898242d6737ba02b74a59a2f2
21+
permissions:
22+
actions: read
23+
contents: read
24+
security-events: write

‎.github/workflows/mirror.yml‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,3 +17,7 @@ jobs:
1717
mirror:
1818
uses: hyperpolymath/standards/.github/workflows/mirror-reusable.yml@bd0df9ead7faf0cdfe0e13e7966d91e28d0101d4
1919
secrets: inherit
20+
permissions:
21+
actions: read
22+
contents: read
23+
security-events: write

‎.github/workflows/scorecard.yml‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ jobs:
1919
scorecard:
2020
uses: hyperpolymath/standards/.github/workflows/scorecard-reusable.yml@bd0df9ead7faf0cdfe0e13e7966d91e28d0101d4
2121
permissions:
22+
actions: read
2223
contents: read
2324
security-events: write
2425
id-token: write

‎.github/workflows/secret-scanner.yml‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ permissions:
2020
jobs:
2121
scan:
2222
permissions:
23+
security-events: write
2324
contents: read
2425
pull-requests: write
2526
actions: read

0 commit comments

Comments
 (0)