Repository navigation
Description
Raised by the owner while reviewing #906 (PR #925): why is this a hand-run make target rather than part of the chart or the deploy? The chart half has a real answer. The deploy half does not.
The chart cannot hold them, and that part is settled
er-platform installs once per namespace — one release per developer plus one for ci. Cluster-scoped objects in a per-namespace chart would mean every install racing for the same object, and a helm uninstall of one developer namespace deleting the NodePools every other namespace runs on. batch-orchestration-design.md already states this for the three PriorityClasses: "Cluster-scoped objects ... cannot live in a per-namespace chart."
The deploy has no excuse
deploy.yml already does every prerequisite:
aws eks update-kubeconfig --name "$CLUSTER"(line ~164)bash scripts/ci/install-helm.shbash scripts/obs_up.sh— a non-chart, cluster-level installer, run from CI with the comment "the same script a human runs"- and its push trigger paths already include
infra/k8s/**
So a commit touching infra/k8s/nodepools/ fires a deploy that then ignores those files. Nothing applies them, and nothing reports that nothing applied them. The Makefile comment admits the surrounding gap in its own words: "infra.yml does not even trigger on these paths, so there is no drift gate either."
What it cost
Measured 2026-11-08 on er-prod, nine days after the cluster was created: no app, runner-sm or runner-l NodePool, no er-task-* PriorityClass, and no amazon-vpc-cni ConfigMap — so every NetworkPolicy object in that cluster enforced nothing, which is §8.5's silent failure and silent precisely because the policies exist and read as healthy. A prod deploy would additionally have sat Pending with no pool to land on.
Scope
Apply infra/k8s/nodepools/, infra/k8s/nodepools/<env>/, infra/k8s/priorityclasses/ and infra/k8s/network-policy-controller.yaml from the deploy, per environment — the same set make cluster-objects ER_ENV=<env> applies, so the script and the human command stay one thing rather than two that can disagree (the obs_up.sh precedent).
Open questions worth deciding rather than defaulting:
- Which workflow.
deploy.ymlis triggered by images completing, and cluster objects do not depend on an image — so it would run them on a trigger that has nothing to do with them. A separate workflow onpush: mainwith apaths:filter is cleaner and is allowed here precisely because it would not be a required check (the no-paths:rule applies only to required workflows). - Credentials for prod. The dev deploy role has a cluster-admin access entry (
envs/dev/eks.tf). Prod needs the equivalent, which Prod deploy path #556 is adding anyway — hence doing this alongside it. - Whether applying is enough.
kubectl applyconverges but never deletes, so a NodePool removed from the tree lingers in the cluster. A drift report (--dry-run=serverand diff) is the cheap version; pruning is the expensive, dangerous version. Pick one deliberately.
Acceptance
- a commit touching only
infra/k8s/nodepools/prod/app.yamlresults in that pool being applied toer-prodwithout anyone running a command - the same code path is what
make cluster-objectsruns, so the two cannot drift - a cluster missing the CNI ConfigMap is reported, not silently converged past — this is the failure that motivated the ticket
- the NetworkPolicy probe from Prod app NodePool, and a per-environment cluster-objects target #906 (no policy → SERVED, default-deny → DENIED) is re-run after the pipeline applies it, since enforcement is the thing being protected
Activity
athvin commentedon Nov 8, 2026
Claimed — working in #931 (draft). Closing that PR releases the claim. The three open questions are decided there: separate non-required workflow on push:main with a paths filter; the per-env deploy roles carry the credentials (prod's arrives with #930); apply + report, never prune.
ci(cluster): apply infra/k8s cluster objects from CI, one code path w…
feat(cluster): ESO install + ClusterSecretStore join cluster_objects.…
chore(skills): regen coverage for the ESO fold-in (#927)
ci(cluster): apply infra/k8s cluster objects from CI, one code path w…
athvin commentedon Nov 9, 2026
Landed: #931 (squash
13358a06) + its first-run fix #940 (2ce11b33).Acceptance:
infra/k8s/...results in the objects applied without anyone running a command — the merge of ci(cluster): apply infra/k8s cluster objects from CI, one code path with make (#927) #931 itself firedcluster-objects.yml(its own file + the script are in its paths); green run on both legs after the alias fix: https://github.com/athvin/entity-resolution-engine/actions/runs/42539710868 — prod leg applied the NodePools/PriorityClasses/CNI ConfigMap, presence verified, zero drift reported.make cluster-objectsruns — both callscripts/cluster_objects.sh <env>; the Makefile target is a one-line wrapper.kubectl get -ffails the run if anything is missing), plus a post-apply convergence diff and report-only deletion drift. On top: the same gap class bit harder than the ticket knew — er-prod also had no ESO controller (hand-installed on dev in task 1.6, never captured; the first prod deploy failed its hooks on it).cluster_objects.shnow installs ESO pinned at 2.12.0 + the ClusterSecretStore on both clusters.app's default-deny on er-api:8000 → DENIED (timeout); theallow-alb-to-webhole correctly admits er-web:3000 (200). Probe namespace deleted.The three open questions, as decided: separate non-required workflow (with the comment marking why it must never become required without dropping the paths filter); the per-env deploy roles carry the credentials; apply + report, never prune.