Skip to content

Commit 0b27cfe

Browse files
authored
Give release.yml actions: write so the dispatch step actually works (#4787)
1 parent 0e53446 commit 0b27cfe

1 file changed

Lines changed: 9 additions & 8 deletions

File tree

.github/workflows/release.yml

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@ on:
4949
permissions:
5050
contents: write # push the version + regen commits and the tag back to main
5151
id-token: write # OIDC token used by `npm publish --provenance`
52+
actions: write # `gh workflow run` against the downstream workflows in the dispatch step
5253

5354
jobs:
5455
release:
@@ -150,15 +151,15 @@ jobs:
150151
# building-docker-release.yml, and the "new version" commit push
151152
# does NOT fire building-docker-autobuild.yml or netlify.yml.
152153
# workflow_dispatch is the one event GITHUB_TOKEN is allowed to
153-
# raise, so kick each one off explicitly here. Failures are
154-
# tolerated (`|| true`) so a transient API hiccup on one dispatch
155-
# doesn't fail an otherwise-successful release — the maintainer
156-
# can re-dispatch any missed workflow by hand from the Actions
157-
# tab.
154+
# raise, so kick each one off explicitly here. `gh workflow run`
155+
# needs the actions: write scope (granted at the workflow level
156+
# above) — without it the calls 403. Errors are surfaced (no
157+
# `|| true`) so a silent dispatch failure can't repeat the
158+
# 41.3.1 / 41.3.2 / 41.3.3 "npm out, Docker missing" outcome.
158159
- name: Dispatch downstream workflows
159160
env:
160161
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
161162
run: |
162-
gh workflow run building-docker-release.yml --ref "${{ steps.bump.outputs.tag }}" || true
163-
gh workflow run building-docker-autobuild.yml --ref main || true
164-
gh workflow run netlify.yml --ref main || true
163+
gh workflow run building-docker-release.yml --ref "${{ steps.bump.outputs.tag }}"
164+
gh workflow run building-docker-autobuild.yml --ref main
165+
gh workflow run netlify.yml --ref main

0 commit comments

Comments
 (0)