Correct the fix: mark the namespace prune-disabled, don't drop it from inventory

Dropping it from resources: was the same accident by a different door — Flux
prunes anything that disappears from a Kustomization's rendered inventory, so
the live Kustomization's next reconcile would have deleted the namespace
itself. Caught before it fired by suspending that Kustomization.

kustomize.toolkit.fluxcd.io/prune: disabled on the object is the documented
way to keep Flux creating/updating a resource while never deleting it.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
Stéphane Tailland
2026-08-31 15:13:32 +02:00
parent 023a89bf71
commit 9eebd5f190
2 changed files with 19 additions and 6 deletions
+1
View File
@@ -1,6 +1,7 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- namespace.yaml
- ca-configmap.yaml
- externalsecret.yaml
- configmap.yaml