feat(reconciler): alert when Actions (CI) enforcement is silently skipped (#183) #202
Inga granskare
Etiketter
Inga etiketter
area/backups
area/ci
area/control-panel
area/identity
area/infra
area/observability
area/payments
area/security
area/storage
area/web
blocked
needs-info
needs-triage
ready-for-implementation
type
bug
type
chore
type
docs
type
epic
type
feature
type
task
wontfix
Ingen milstolpe
Inget projekt
Inga tilldelade
1 deltagare
Notiser
Förfallodatum
Inget förfallodatum satt.
Beroenden
Inga beroenden satta
Referens
bitborg/bitborg-infra!202
Läser in…
Hänvisa till i nytt ärende
Ingen beskrivning angiven.
Ta bort grenen "feat/183-reconciler-actions-degraded-alert"
Borttagning av en gren är permanent. Även om den borttagna grenen kan fortsätta existera en kort tid innan den faktiskt tas bort, kan det INTE ångras i de flesta fall. Vill du fortsätta?
Closes #183.
Problem
The reconciler's per-repo Actions (
has_actions) toggle needsread:user/read:organization+write:repository. When the admin token lacks those,set_repo_actionslogs a WARN and returns — the run still succeeds (status 0) while CI tier gating (the grant and the default-deny bypass-prevention, #37/#125 M4) quietly stops being enforced. This was invisible: no metric, no alert, just a WARN nobody reads.Making it fatal is the wrong fix — it would couple the Actions toggle's failure to the critical quota/org enforcement in the same run (the original cause of the reconciler failing every run). The toggle must remain best-effort.
Fix — make it alertable, not fatal
$TEXTFILE_DIR/.reconciler-actions-degraded, reset each run) is set whenever the toggle is skipped/failed: list curl error, list non-200 (scope), or PATCH non-2xx (write:repository). Marker file, not a shell global, so it survives any subshell in the owner loops.write_reconciler_metricemitsgitborg_reconciler_actions_enforcement_degraded {0,1}alongside the existing status/timestamp — so it's recorded on both the success path and the EXIT-trap failure path.== 1for: 1h, warning): a persistent scope problem pages; a one-off transient doesn't.Fix path when it fires: broaden the reconciler token (runbook Actions-tier token note). Not applied yet — monitoring role change, review + apply via infra-apply.
supernaut refererade till denna ändringsförfrågan2026-07-26 21:14:05 +00:00