You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm seeing the following when installing the chart in this PR helm/charts#2369
$ helm install --name istio . --namespace istio-system
Error: unable to decode "": no kind "CustomResourceDefinition" is registered for version "apiextensions.k8s.io/v1beta1"
If I render the files with CRDs manually using helm template and install using kubectl create -f they work just fine.
Reacted by johackim, Paul Dilyard, Tom Clift, Nick Muller, Scott Ganyo, Victor Sollerhed, Levi Blackstone, David X Johnson, Pieter Lange, Moody Saada and 3 more
In this chart the services aren't creating the CRDs. The chart itself creates the CRDs. I've used hooks to order the creation but Helm is having trouble applying them to Kubernetes
Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.
Prevent issues from auto-closing with an /lifecycle frozen comment.
If this issue is safe to close now please do so with /close.
Send feedback to sig-testing, kubernetes/test-infra and/or @fejta.
/lifecycle stale
I am using helm in an OpenShift setup, and trying to manage everything using helm hitting ordering issues very hard...
In OpenShift there is a CRD called Project, which is a complete replacement of Namespace (it then creates a "virtual" Namespace object Read-Only), thus when I try creating a Project with Quotas, and other official objects from k8s the ordering is messed up.
@dabelenda I've suggested elsewhere that subcharts in requirements.yaml could be weighted/ordered. Then you could split deployments into phases and control the order at that level? #1780 (comment)
It would be nice to be able to e.g. apply weights to subcharts in requirements.yaml, with charts of the same weight being sorted together with the current algorithm. All weights, including parent chart would be zero by default. Negative weights would install before the parent chart, positive weights would install after.
With this optional feature the processing of all existing charts would be unaffected. And only people who really need ordering would specify any weights for requirements.yaml.
Reacted by Luis Davim, Alec Buckenheimer, EviSONG, Eugen and Jannik Hollenbach
I am "only" creating the Project, Quotas, and RoleBindings here.
The need to create a dummy subchart to only create a Project and then apply Quotas and RoleBindings is weird.
Every single CRD that have dependencies will have to be in different subcharts. It would creates hard-to-understand charts if the dependency tree is non trivial.
I think of Prometheus-Operator Prometheus ServiceMonitoring etc
Hey @Ciantic and @JulienBreux so this is because your local types/discovery cache is stale after you install a CRD. We have handled this with the new crds/ directory installation in Helm 3. It will invalidate the cache for you. This is due to the way Kubernetes discovery caching works and not due to Helm itself per se. To get around it, you can delete ~/.kube/cache/discovery (or append the cluster name to the end of the path to just remove its specific cache) in between running the install of Istio init and installing Istio itself
You are right. Apparently istio can't be installed with helm3, and probably never will be, because they are working on a different installer. See istio/istio#17167
Activity
redbaron commentedon Oct 2, 2017
Look at prometheus-operator, helm is not waiting for third party resource to become fully registered, therefore one off install hook is necessary
lachie83 commentedon Oct 2, 2017
In this chart the services aren't creating the CRDs. The chart itself creates the CRDs. I've used hooks to order the creation but Helm is having trouble applying them to Kubernetes
bacongobbler commentedon Oct 2, 2017
Is this a cascading failure from #2995? Let's try the proposed fix in that issue first and see if that fixes things.
lachie83 commentedon Oct 2, 2017
This didn't help. I believe there's some funniness when using CRDs/TPRs with hooks. #2680
thomastaylor312 commentedon Oct 6, 2017
Related: #2925
thomastaylor312 commentedon Oct 7, 2017
As a note, we are going to pull the ordering part of this into 2.7
thomastaylor312 commentedon Oct 11, 2017
Pulling this out of 2.7 in favor of #2925
fejta-bot commentedon Jan 9, 2018
Issues go stale after 90d of inactivity.
Mark the issue as fresh with
/remove-lifecycle stale.Stale issues rot after an additional 30d of inactivity and eventually close.
Prevent issues from auto-closing with an
/lifecycle frozencomment.If this issue is safe to close now please do so with
/close.Send feedback to sig-testing, kubernetes/test-infra and/or
@fejta./lifecycle stale
thomastaylor312 commentedon Jan 9, 2018
/lifecycle frozen
24 remaining items
kfox1111 commentedon Dec 7, 2018
and certmanager
paktek123 commentedon Jan 7, 2019
I get same thing as @fiunchinho but for heptio-ark when trying to upgrade/install
dabelenda commentedon Feb 18, 2019
I am using helm in an OpenShift setup, and trying to manage everything using helm hitting ordering issues very hard...
In OpenShift there is a CRD called Project, which is a complete replacement of Namespace (it then creates a "virtual" Namespace object Read-Only), thus when I try creating a Project with Quotas, and other official objects from k8s the ordering is messed up.
I think a good way to let users control ordering with CRDs, would be to, instead of having a static ordering like defined here https://github.com/helm/helm/blob/release-2.13/pkg/tiller/kind_sorter.go#L29 use an integer priority to each object and allow users to set a priority for Kinds in metadata of the chart or something.
whereisaaron commentedon Feb 18, 2019
@dabelenda I've suggested elsewhere that subcharts in
requirements.yamlcould be weighted/ordered. Then you could split deployments into phases and control the order at that level?#1780 (comment)
dabelenda commentedon Feb 18, 2019
I am "only" creating the Project, Quotas, and RoleBindings here.
The need to create a dummy subchart to only create a Project and then apply Quotas and RoleBindings is weird.
Every single CRD that have dependencies will have to be in different subcharts. It would creates hard-to-understand charts if the dependency tree is non trivial.
I think of Prometheus-Operator Prometheus ServiceMonitoring etc
Ciantic commentedon Sep 14, 2019
I'm using helm3 and experience the same problem sporadically, this time with istio resources:
Error: apiVersion "config.istio.io/v1alpha2" in istio/charts/mixer/templates/config.yaml is not availableIt works occasionally, but most often it just throws me that error. It doesn't happen always.
JulienBreux commentedon Sep 17, 2019
Error
Versions
version.BuildInfo{Version:"v3.0.0-beta.3", GitCommit:"5cb923eecbe80d1ad76399aee234717c11931d9a", GitTreeState:"clean", GoVersion:"go1.12.9"}thomastaylor312 commentedon Sep 18, 2019
Hey @Ciantic and @JulienBreux so this is because your local types/discovery cache is stale after you install a CRD. We have handled this with the new
crds/directory installation in Helm 3. It will invalidate the cache for you. This is due to the way Kubernetes discovery caching works and not due to Helm itself per se. To get around it, you can delete~/.kube/cache/discovery(or append the cluster name to the end of the path to just remove its specific cache) in between running the install of Istio init and installing Istio itselfCiantic commentedon Sep 18, 2019
@thomastaylor312 it doesn't work. I guess because the main
istiochart also tries to install crds?Throws error:
Only thing that works 100% time is normal
kubectl apply -fmethod.I want to note that above script works sometimes but usually not. So something funny and non-deterministic there is.
bacongobbler commentedon Sep 18, 2019
Probably because support for the crd-install hook was dropped in Helm 3 in favour of a
crddirectory.Ciantic commentedon Sep 18, 2019
You are right. Apparently istio can't be installed with helm3, and probably never will be, because they are working on a different installer. See istio/istio#17167
bacongobbler commentedon May 14, 2020
closing as resolved with the
crdsdirectory. For further discussion on CRDs and Helm, please see #5871. Thanks.cannot use Helm 3's crds/ folder mechanism
do not use Helm 3's crds/ folder that uses crd pre-install hook