Repository navigation
Description
Auto Deploy Backend Pusher to GKE (Development) has failed on every push to main since 2026-08-05 15:20 UTC (30+ consecutive runs; latest run 31251722854 on 0afc7b9c79). It always dies at the same step, before any Helm mutation:
FAIL: insufficient schedulable Pusher headroom for the next surge wave:
need 700m CPU and 2147483648 bytes memory for 1 surge pod(s)
Consequence: the dev Pusher has not been deployed for 4+ days. dev-omi-pusher-8649b95594-wn66w is 4d4h old on pusher@sha256:b69c2d75… (revision 210), while CI has been building sha256:46128d7b…. Dev is not qualifying the code that prod promotion is selected from.
This is not a capacity shortage — the gate cannot pass on this topology
backend/scripts/verify_pusher_live_deployment_gate.py (capacity_evidence → node_matches_pod) only counts currently Ready, schedulable nodes. It has no model of the cluster autoscaler. Measured live against dev-omi-gke just now (same code path as CI, same digest):
| value | |
|---|---|
candidate nodes (match service=pusher,env=dev + dedicated=pusher toleration) |
1 — gke-dev-omi-gke-pusher-pool-a7e64326-1zht |
| node allocatable | 1930m CPU / 5535Mi |
| already requested on it | 1424m CPU / 3530Mi (700m/2Gi = the live Pusher pod, rest kube-system daemons) |
| free | 506m CPU / 2005Mi |
| needed for 1 surge pod | 700m CPU / 2048Mi |
But pusher-pool is an autoscaling pool, min 1 / max 10 (gcloud container node-pools list --cluster dev-omi-gke). The autoscaler would provision the node the surge pod needs — it never gets the chance, because the gate fails before Helm runs, so no Pending pod is ever created for it to react to. Deadlock.
And on n1-standard-2 (1930m allocatable) this can never resolve itself while the pool sits at one node: 700m live pod + ~724m daemons leaves under 700m, with maxUnavailable: 0, maxSurge: 1 (backend/charts/pusher/dev_omi_pusher_values.yaml:374-377) requiring a second pod before the first goes away. Every green run before 08-05 was luck about how much of that node the daemons happened to hold.
The workflow has no workflow_dispatch and no break-glass input, so there is no hatch — contra root AGENTS.md ("Every gated surface has a break-glass hatch").
Why the obvious workaround doesn't work
Setting dev to maxUnavailable: 1, maxSurge: 0 (a 1-replica dev service can tolerate a moment of downtime) trips a different hard failure — surge_count rejects it outright:
if surge < 1:
raise GateError("rendered Pusher maxSurge must provide at least one surge pod")verify_pusher_live_deployment_gate.py:260-261
So the gate mandates surge-based rollout and simultaneously refuses to believe the surge node can be created. Any real fix has to touch the gate.
Proposed fix (needs a backend/deploy owner — has prod blast radius)
The same script gates the prod lane (gcp_backend_pusher.yml) as well as dev (gcp_backend_pusher_auto_deploy.yml), so this should not be patched casually. Options, cheapest first:
- Make the gate autoscaler-aware. When no Ready node fits, read the pool's
autoscaling.maxNodeCountvs current node count for the pools whose labels/taints match the pod spec; if the pool can still grow and one empty node of that machine type would fit the surge pod (allocatable minus DaemonSet requests ≥ request), pass with evidence naming the pool and the headroom it will come from. Keep failing closed when the pool is already at max, or when even a fresh node is too small — which is the case the gate was actually written for. - Allow surge-free rollout where the values ask for it. Drop the
surge < 1hard error; whenmaxSurge: 0andmaxUnavailable ≥ 1, verify the replacement pod fits after the old one is evicted (i.e. on the node the old pod is leaving) instead of demanding simultaneous headroom. Then dev can setmaxSurge: 0. - Add the missing break-glass (
workflow_dispatch+skip_capacity_gate/ reason), per theAGENTS.mdhatch rule, so a broken gate stops meaning a stuck lane. - Ops stopgap only: raise
pusher-poolmin to 2 or move dev Pusher to a larger machine type. This unblocks today but the autoscaler will scale back down to 1 when idle and the lane re-breaks — it is not a fix.
Option 1 + 3 together is the durable shape: the gate keeps its fail-closed purpose for genuinely unschedulable pods, and stops treating "the autoscaler has not been asked yet" as "no capacity exists."
Reproduce locally
python3 backend/scripts/verify_pusher_live_deployment_gate.py \
--environment dev --namespace dev-omi-backend \
--image gcr.io/based-hardware-dev/pusher@sha256:46128d7b1a8c36045b3aad14ee493e5f2b1ba2656881650fc8256d2762fb575a
# FAIL: insufficient schedulable Pusher headroom ... (identical to CI)
Filed rather than fixed: the fix relaxes a fail-closed deployment gate shared with the prod Pusher lane, which wants an owner's sign-off, and it cannot be end-to-end verified without running a real dev deploy. Prior triage passes have repeatedly written this red off as "dev GKE capacity / infra" — the min 1 / max 10 autoscaling config above is the evidence that it is not.
Metadata
Metadata
Assignees
Labels
Type
Projects
- StatusShow more project fieldsIn review
Activity
kodjima33 commentedon Aug 8, 2026
Same root cause just took down a second lane:
Auto Deploy Backend to Developmentfailed ond382cd5at 13:04Z (run 31258039027) — first failure of that lane today (12:29Z, 11:27Z, 10:47Z, 09:59Z all green).Failing step is the pre-promotion LLM-gateway smoke:
It is not the gateway image — the pod never got scheduled. Live evidence from
dev-omi-gkejust now:The smoke pod is a bare
kubectl runwith nonodeSelectorand no tolerations, so the only node it can land on is the single untaintedmonitoring-poolnode, which is saturated:default-poolhas autoscaling enabled but nominNodeCountand currently zero nodes, so nothing absorbs the burst; the 60skubectl runwait is shorter than a node scale-up, so the step fails deterministically whenever the cluster is at this level of pressure.Suggested ops fix (no code change needed to unblock): set
default-pool--min-nodes=1ondev-omi-gke, or give the smoke pod a toleration/nodeSelector for an existing pool. A code fix would have to raise the smoke step's wait past node-scale-up time, but that lives in.github/workflows/, so flagging rather than patching.🤖 hourly watchdog — evidence only, no PR opened.
fix(deploy): model Pusher surge capacity the way the scheduler and au…