1.0.6 uninstall deletes CRDs

How do I save my CRDs and resources when I upgrade Istio from 1.0.6 to version 1.1.

I did a helm template install/kubernetes/helm/istio piped to kubectl apply -f - when installing version 1.0.6.

So, wondering if there is a flag that I can set to uninstall Istio version 1.0.6, so that I can skip uninstalling CRDs

Oh, and I am installing the CRDs using
kubectl apply -f install/kubernetes/helm/istio/templates/crds.yaml

So, I read up the issues regarding different Helm versions and annotation “helm.sh/hook”: crd-install.
I am using Helm version 2.9.1 (< 2.10).

Deleting CRDs and Istio Configuration
Istio, by design, expects Istio’s Custom Resources contained within CRDs to leak into the Kubernetes environment. CRDs contain the runtime configuration set by the operator. Because of this, we consider it better for operators to explicitly delete the runtime configuration data rather than unexpectedly lose it.

But based on the CRD information, I am expecting CRDs to “leak” into k8s cluster. But they are not leaking. They are getting removed when I perform kubectl delete.

Is there a way, for me to retain the CRDs?

The workaround I was able to do was to manually modify install/kubernetes/helm/istio/values.yaml, to set crds: false

  # Include the crd definition when generating the template.
  # For 'helm template' and helm install > 2.10 it should be true.
  # For helm < 2.9, crds must be installed ahead of time with
  # 'kubectl apply -f install/kubernetes/helm/istio/templates/crds.yaml
  # and this options must be set off.
  crds: false <-- line # 189

during uninstall.

I am looking to find if there is an automated way of doing this, in Helm?

I did try –set crds=false in helm template …, but it didn’t work.

Any help on this is appreciated!