From 0905f5ca865f1a57f0fc099c276feba86989d2ef Mon Sep 17 00:00:00 2001 From: duynguyen Date: Wed, 2 Sep 2026 23:12:00 +0700 Subject: [PATCH] fix: ServerSideApply on argocd Application to prune stale fields argocd was originally helm-installed by hand before ArgoCD existed to manage it; client-side 3-way merge apply can't prune fields it never saw in a last-applied-configuration, so a later chart bump left a stale args on repo-server's copyutil init container (old shell-string command lingering alongside the new plain cp command) -> cp got 4 args instead of 3 -> 'No such file or directory' -> CrashLoopBackOff -> Degraded. Same bug class as envoy-gateway (020b248). ServerSideApply=true tracks field ownership properly and prunes the stray field on next sync. --- bootstrap/apps/argocd.yaml | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/bootstrap/apps/argocd.yaml b/bootstrap/apps/argocd.yaml index 895c19d..19e27d1 100644 --- a/bootstrap/apps/argocd.yaml +++ b/bootstrap/apps/argocd.yaml @@ -20,3 +20,12 @@ spec: destination: server: https://kubernetes.default.svc namespace: argocd + # ArgoCD was originally `helm install`ed by hand before ArgoCD existed to + # manage it (see README Phase 3), so client-side 3-way merge apply can't + # see/prune fields from that pre-existing object — left a stale `args` on + # argocd-repo-server's copyutil init container after a later chart bump, + # crashlooping it (same bug class as envoy-gateway, see 020b248). + # ServerSideApply properly tracks field ownership and prunes it. + syncPolicy: + syncOptions: + - ServerSideApply=true