Skip to content
Merged
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
e15424a
chore(ci): define the build-and-deploy graph once (ENG-1053)
lucas-koontz Jul 26, 2026
5dacfce
chore(ci): enhance workflow checks and refactor for external usage (E…
lucas-koontz Jul 26, 2026
b564c9a
docs: clarify secret storage guidelines in README (ENG-1053)
lucas-koontz Jul 26, 2026
a07afe4
Merge branch 'main' into chore/eng-1053-startup-failure-watchdog
lucas-koontz Jul 26, 2026
ba609bc
chore(workflow): refine PR environment comment security and improve w…
lucas-koontz Jul 26, 2026
b021bbc
chore(workflow): enhance heading customization for PR environment com…
lucas-koontz Jul 26, 2026
21e54cc
Merge remote-tracking branch 'origin/main' into chore/eng-1053-startu…
lucas-koontz Jul 27, 2026
90b1a49
chore(workflow): refine secret retrieval check to skip comments (ENG-…
lucas-koontz Jul 27, 2026
bf2005a
Merge remote-tracking branch 'origin/main' into chore/eng-1053-startu…
lucas-koontz Jul 27, 2026
67300f0
chore(workflow): implement absent state messaging for PR environments…
lucas-koontz Jul 27, 2026
729b49c
chore(workflow): unify environment link tables in PR comments (ENG-1053)
lucas-koontz Jul 27, 2026
a613ca9
Merge branch 'main' into chore/eng-1053-startup-failure-watchdog
lucas-koontz Jul 27, 2026
9529a81
chore(workflow): enhance failure notification to handle re-runs (ENG-…
lucas-koontz Jul 27, 2026
4a1ed20
Merge branch 'main' into chore/eng-1053-startup-failure-watchdog
lucas-koontz Jul 27, 2026
62126e8
chore(workflow): update actions/checkout and docker/setup-buildx-acti…
lucas-koontz Jul 27, 2026
3eb1e36
chore(workflow): enhance advisory output with detailed rule counts (E…
lucas-koontz Jul 27, 2026
426adbf
Merge branch 'main' into chore/eng-1053-startup-failure-watchdog
lucas-koontz Jul 27, 2026
54c87bc
chore(workflow): enhance Slack payload with text for accessibility (E…
lucas-koontz Jul 27, 2026
594f074
Merge branch 'main' into chore/eng-1053-startup-failure-watchdog
lucas-koontz Jul 27, 2026
791acbb
chore(workflow): refine permissions logic in notify-main-failure.yml …
lucas-koontz Jul 27, 2026
b19b9aa
Merge branch 'main' into chore/eng-1053-startup-failure-watchdog
lucas-koontz Jul 27, 2026
5375cde
chore(workflow): reintroduce permissions block for notify-main-failur…
lucas-koontz Jul 27, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 6 additions & 26 deletions .github/workflows/notify-main-failure.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,8 @@
# secrets: inherit
#
# A failure-only caller (the freeze/unfreeze wrappers) keeps `if: failure()`,
# takes the default `status: failed`, and needs no `permissions:` block at all:
# the prior-run lookup only runs in recovered mode, and this workflow declares no
# scopes of its own (see the note above `jobs:`), so there is no floor to clear.
# Granting only `contents: read` is correct there and stays valid.
# takes the default `status: failed`, and needs no `permissions:` block: the
# prior-run lookup only runs in recovered mode.
#
# Requires (reach this workflow via `secrets: inherit` in the caller):
# - secrets.SLACK_ENG_CHANNEL_ID (the engineering channel; org secret)
Expand Down Expand Up @@ -90,28 +88,10 @@ on:
type: string
default: ubuntu-latest

# DELIBERATELY NO `permissions:` BLOCK. This job inherits whatever the caller
# granted, which is the only shape that works for a reusable with two kinds of
# caller.
#
# A block here would be a floor every caller has to clear, not a ceiling. GitHub
# validates a called workflow's requested scopes when the CALLER is parsed,
# against the caller's grant, with no knowledge of which steps will run — so
# declaring `actions: read` (which only the recovery lookup needs, and only in
# recovered mode) rejected every failure-only caller outright:
#
# The workflow is requesting 'actions: read', but is only allowed 'actions: none'
#
# That is a load failure, not a degraded run: the workflow does not fail its
# notify job, it fails to exist. Fourteen freeze/unfreeze workflows across seven
# repos were invalid from the moment their notify job landed, unnoticed because
# freeze runs weekly.
#
# Inheriting instead gives each caller what it actually needs: a recovery-mode
# caller grants `contents: read` + `actions: read` and the lookup works; a
# failure-only caller grants `contents: read`, never reaches the lookup, and
# stays valid. If a caller ever asks for recovery without the grant, the lookup
# already fails quiet and stays silent rather than reddening a green run.
permissions:
contents: read
actions: read # read the previous run's conclusion for recovery detection

jobs:
notify:
runs-on: ${{ inputs.runs-on }}
Expand Down
Loading