UNCLASSIFIED - NO CUI

Fix argocd-apps CRD install ordering

Summary

  • Add Argo CD Application, ApplicationSet, and AppProject CRD bootstrap copies to the parent chart crds/ install path so Helm installs those CRDs before rendering argocd-apps resources in the same release.
  • Keep upstream.crds.install=true so the vendored upstream argo-cd chart still renders/applies its CRD manifests during normal upgrades.
  • Keep the upstream argocd-apps chart rendering normally instead of maintaining a Big Bang copy of its templates.
  • Add unit coverage for argocd-apps.applications rendering through the upstream subchart.
  • Add scripts/sync-upstream-crds.sh and maintenance-guide steps so future upstream argo-cd dependency bumps refresh and check the parent chart/crds/ copies.

The hook workaround was tested and is not the best package fix. Helm still needs to resolve the Application kind while processing hook resources, so hook annotations on argocd-apps resources do not reliably solve fresh installs.

A Big Bang umbrella post-renderer is not needed for this MR. Post-renderers operate after Helm has rendered the chart and cannot turn a templated CRD into a pre-render/pre-discovery CRD phase. A larger umbrella split release for argocd-apps would also work architecturally, but it requires separate HelmRelease/source wiring and value migration. This package-local fix keeps the existing values contract and does not modify upstream charts.

The parent chart/crds/ files are rendered from the vendored upstream argo-cd chart tarball. Future dependency updates should run scripts/sync-upstream-crds.sh, and scripts/sync-upstream-crds.sh --check verifies those copies have not drifted from upstream.

Validation

  • scripts/sync-upstream-crds.sh --check
  • helm lint chart/
  • helm unittest chart/ -f 'unittests/*.yaml'
  • cd /Users/mvasquez/repos/bb/bigbang && ./docs/reference/scripts/developer/k3d-dev.sh -a -t argocd309
  • Big Bang umbrella deployment to k3d-dev with Argo CD enabled and the package pinned to fix/issue-309-argocd-apps-crd-ordering
  • kubectl get gitrepository argocd -n bigbang confirmed the fix branch revision 3d2e9d05c66a87c01b6b4238d99eea8549621794
  • kubectl get helmrelease argocd -n bigbang confirmed the Argo CD HelmRelease is Ready after the umbrella/Flux deployment
  • kubectl get crd applications.argoproj.io applicationsets.argoproj.io appprojects.argoproj.io confirmed all Argo CD app CRDs are present with Helm ownership metadata
  • kubectl get application podinfo -n argocd confirmed podinfo from argocd-apps is Synced and Healthy
  • Argo CD UI confirmed the podinfo application is Healthy and Synced

Supporting Evidence

Local chart validation:

argocd309-local-validation

k3d-dev Big Bang umbrella deployment through Flux showing the Argo CD HelmRelease Ready, CRDs present with Helm ownership metadata, and podinfo Synced / Healthy:

argocd309-flux-terminal-evidence

Argo CD UI showing the podinfo application from argocd-apps as Healthy and Synced:

argocd309-podinfo-ui-hostname

Linked issues

#309 (closed)

Upgrade Notices

Argo CD CRDs now have bootstrap copies in the parent chart crds/ directory. upstream.crds.install remains enabled, so upstream CRD templates are still rendered/applied for upgrades.

Existing CRDs retain the upstream helm.sh/resource-policy: keep behavior.

Edited by Matt Vasquez

Merge request reports

Loading
Loading