diff --git a/cli/cmd/deploy_components.go b/cli/cmd/deploy_components.go index 3c9dfeaa..49a71818 100644 --- a/cli/cmd/deploy_components.go +++ b/cli/cmd/deploy_components.go @@ -782,8 +782,12 @@ func deployGroupA(dc *deployContext) error { // // --reset-values: pre-chart releases stored flat upstream keys that // now live under the subchart key, and the schema rejects them. + // + // --skip-crds: applyLocalStrimziCRDs already applied them as the + // "kubectl" field manager; Helm 4 re-applying crds/ on a fresh + // install conflicts with it over .spec.versions. opArgs := []string{"upgrade", "--install", "strimzi-operator", chartDir, "-n", "strimzi-operator", - "--reset-values", + "--reset-values", "--skip-crds", "-f", dc.chartOverlay("charts/strimzi-operator"), "--set", "strimzi-kafka-operator.kubernetesServiceDnsDomain=" + clusterDomain, "--set", "crdUpgrade.enabled=false"} diff --git a/cli/cmd/deploy_components_test.go b/cli/cmd/deploy_components_test.go index d1e94f6d..4e31bd5b 100644 --- a/cli/cmd/deploy_components_test.go +++ b/cli/cmd/deploy_components_test.go @@ -478,6 +478,7 @@ func TestDeployGroupAAppliesLocalStrimziCRDsAndDisablesHook(t *testing.T) { for _, want := range []string{ "upgrade --install strimzi-operator /cache/wrapper/1.2.0", "--set crdUpgrade.enabled=false", + "--skip-crds", "--set strimziVersion=1.2.0", "--set strimzi-kafka-operator.kubernetesServiceDnsDomain=cluster.test", } {