Add an optional mode/flag to scaffold a separate chart for CRDs (as a subchart or sibling chart). This is intended for advanced use cases and to align with Helm best practices around CRD installation and chart ordering.
References:
Motivation
Today the Helm plugin places CRDs under templates/crd so Helm applies them like normal resources and upgrades them (Helm’s crds/ directory installs once and does not manage upgrades). This is intentional.
However, there are common operational needs where users want:
- CRDs installed ahead of everything else (and potentially by cluster admins)
- a clean separation between “cluster-scoped API installation” (CRDs) and “namespaced operator installation”
- the ability to install CRs after CRDs are registered (without relying on hooks)
Helm docs explicitly describe the “separate charts” approach for CRDs/resources ordering.
Proposed feature
Introduce an optional flag/mode for the Helm plugin, for example:
kubebuilder edit --plugins=helm/v2-alpha --crd-chart
Expected output (one possible layout)
subchart dependency
dist/chart/
charts/<project>-crds/ (CRDs only, installed separately or as dependency)
- (document recommended install ordering)
Add an optional mode/flag to scaffold a separate chart for CRDs (as a subchart or sibling chart). This is intended for advanced use cases and to align with Helm best practices around CRD installation and chart ordering.
References:
Motivation
Today the Helm plugin places CRDs under
templates/crdso Helm applies them like normal resources and upgrades them (Helm’scrds/directory installs once and does not manage upgrades). This is intentional.However, there are common operational needs where users want:
Helm docs explicitly describe the “separate charts” approach for CRDs/resources ordering.
Proposed feature
Introduce an optional flag/mode for the Helm plugin, for example:
kubebuilder edit --plugins=helm/v2-alpha --crd-chartExpected output (one possible layout)
subchart dependency
dist/chart/charts/<project>-crds/(CRDs only, installed separately or as dependency)