Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

kubeVersion in Trident Helm chart can't handle pre-releases #530

Closed
scaleoutsean opened this issue Feb 16, 2021 · 13 comments
Closed

kubeVersion in Trident Helm chart can't handle pre-releases #530

scaleoutsean opened this issue Feb 16, 2021 · 13 comments

Comments

@scaleoutsean
Copy link
Contributor

scaleoutsean commented Feb 16, 2021

Describe the bug

kubeVersion in Trident Helm chart can't handle pre-releases:

$ helm install trident trident-operator --namespace trident --create-namespace
Error: chart requires kubeVersion: >= 1.16.0 < 1.21.0 which is incompatible with Kubernetes v1.20.2-34+350770ed07a558

Environment

  • Trident 21.01.01
  • Kubernetes v1.20.2 pre-release
$ helm version
version.BuildInfo{Version:"v3.5.2", GitCommit:"167aac70832d3a384f65f9745335e9fb40169dc2", GitTreeState:"dirty", GoVersion:"go1.15.7"}

$ kubectl version
Client Version: version.Info{Major:"1", Minor:"20+", GitVersion:"v1.20.2-34+350770ed07a558", GitCommit:"350770ed07a558ba1ce8202a6f9ea849f9a75f06", GitTreeState:"clean", BuildDate:"2021-02-11T20:09:31Z", GoVersion:"go1.15.8", Compiler:"gc", Platform:"linux/amd64"}
Server Version: version.Info{Major:"1", Minor:"20+", GitVersion:"v1.20.2-34+350770ed07a558", GitCommit:"350770ed07a558ba1ce8202a6f9ea849f9a75f06", GitTreeState:"clean", BuildDate:"2021-02-11T20:10:29Z", GoVersion:"go1.15.8", Compiler:"gc", Platform:"linux/amd64"}

To Reproduce

  • Install against a Kubernetes pre-relase

Expected behavior

$ helm install trident trident-operator --namespace trident --create-namespace 
NAME: trident
LAST DEPLOYED: Tue Feb 16 14:50:43 2021
NAMESPACE: trident
STATUS: deployed
REVISION: 1
TEST SUITE: None
NOTES:
Thank you for installing trident-operator, which will deploy and manage NetApp's Trident CSI
storage provisioner for Kubernetes.

Edit - additional notes:

  • I thought I could fix this by loosening the condition but couldn't. I created a Helm issue #9371 for this problem.
  • Simple workaround: verify K8s version meets chart requirements, mark out kubeVersion in the chart file, and then install
@adkerr
Copy link
Contributor

adkerr commented Feb 16, 2021

Just out of curiosity, did you try using helm install --devel?

@scaleoutsean
Copy link
Contributor Author

I went back, reinstalled and tried with --devel, same problem.

@wonderland
Copy link

Jut for the record, this also impacts k8s distributions that report a version string that looks like a pre-release. For example, on a GKE cluster:

helm install trident ./helm/trident-operator-21.01.1.tgz --namespace trident --create-namespace
Error: chart requires kubeVersion: >= 1.16.0 < 1.21.0 which is incompatible with Kubernetes v1.17.15-gke.800

Anyway, the fix in #531 addresses that.

@scaleoutsean
Copy link
Contributor Author

"< 1.21.0-0" worked, but ">= 1.16.0, < 1.21.0-0" didn't, which tripped me in the earlier PR. The Helm guys figured out both (all) conditions are eval'd so ">= 1.16.0-0, < 1.21.0-0" is the way to go (with or without a v).

I submitted #532.

@djjudas21
Copy link

This also affects OpenShift/OKD - I'm on OKD 4.6 which packages Kubernetes 1.20:

Error: chart requires kubeVersion: >= 1.16.0 < 1.21.0 which is incompatible with Kubernetes v1.20.0-1054+bafe72fb05eddc-dirty

@wonderland
Copy link

Well, the version string identifies it as a pre-release. If it isn't one, then they simply use semantic versioning incorrectly ;-)

See https://semver.org/#spec-item-9

But anyway, this will address it with the next Trident release: ce3d442

@djjudas21
Copy link

Feel free to take it up with Red Hat, I'm sure they will listen 😉

I'm running a stable release of OKD but I don't know exactly how they assemble their packages.

Thanks for the update 🙂

@scaleoutsean
Copy link
Contributor Author

You could just make a small edit until new Trident release is out. Or, of course, use another method of installation.

https://github.com/NetApp/trident/pull/532/files

@Cajga
Copy link

Cajga commented Jun 11, 2021

I would like to drop in that this makes trident helm chart uninstallable on AWS EKS:

$ helm install trident-operator -n trident trident-operator-21.04.0.tgz 
Error: chart requires kubeVersion: >= 1.16.0 < 1.22.0 which is incompatible with Kubernetes v1.20.4-eks-6b7464

@wonderland
Copy link

You can still install if you supply "--set tridentSkipK8sVersionCheck=true" to helm.

@Cajga
Copy link

Cajga commented Jun 14, 2021

@wonderland thanks for the workaround.
We are automating the installation of the software on top of kubernetes. Unfortunately, each of such workarounds makes the system more complex.

@wonderland
Copy link

I agree, it is a work around, not a final solution. Hopefully it will be addressed soon in the official chart.

@gnarl
Copy link
Contributor

gnarl commented Jun 23, 2021

This is fixed with commit and will be included with the Trident 21.07 release.

@gnarl gnarl closed this as completed Jun 23, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants