Update or use the latest version of kube-prometheus-stack? - kubernetes-helm

Question is: we have some version of kube-prometheus-stack (https://artifacthub.io/packages/helm/prometheus-community/kube-prometheus-stack) for example version 20.0.0. I want to install just version 40.0.0. Based on docs I should install crd's by using kubectl apply -f somecrd. Can I just install version 40.0.0 which is just working and has all of those crd's alteady installed?
Thanks
Update from 20.0.0 to 24.0.0 - always problems with crd
I just want the latest version of kube-prometheus-stack

Related

Why helm chart cannot be install on Microk8s?

I am using microk8s to run Kubernetes on my Ubuntu server. I am using the helm v3 as my helm command.
This is the result of the helm version command:
version.BuildInfo{Version:"v3.9.2", GitCommit:"1addefbfe665c350f4daf868a9adc5600cc064fd", GitTreeState:"clean", GoVersion:"go1.17.12"}
I am trying to run this helm chart on this K8s instance:
apiVersion: v2
name: myTest
description: The test daemon (test) helm chart
type: application
version: 1.4.0
appVersion: v1.18.0
kubeVersion: ">= 1.19.0"
...
But I am getting this error:
INSTALLATION FAILED: chart requires kubeVersion: >= 1.19.0 which is incompatible with Kubernetes v1.19.15-34+c064bb32deff78
I tried different versions of Microk8s as 1.21, 1.24, and 1.19 but there is the same result.
I installed this service on minikube without any problem :(
According to the Semantic Versioning specification you have a pre-release version of Kubernetes. (This is possibly an issue in microk8s's release process.) The Helm documentation for the kubeVersion: field states that it depends on the Go github.com/Masterminds/semver package. Its documentation notes:
SemVer comparisons using constraints without a prerelease comparator will skip prerelease versions. For example, >=1.2.3 will skip prereleases when looking at a list of releases while >=1.2.3-0 will evaluate and find prereleases.
So setting in your Chart.yaml that you're willing to tolerate pre-release versions should address this:
kubeVersion: ">= 1.19.0-0" # adding a -0 on the end

When to use --version option in helm upgrade

I'm trying to understand when and how --version option in helm upgrade works. In the docs it says:
--version string Specify the exact chart version to use. If this is not specified, the latest version is used
Lets say I have installed my app.
helm install my-app-rls my-app-1.0.0.tgz
Now, If I update my chart and create another package my-app-1.0.1.tgz I can upgrade by
helm upgrade my-app-rls my-app-1.0.1.tgz
Chart.yaml of my-app-1.0.1.tgz already contains a version. When does --version need to be used? What is the use case of it?
You use --version when pulling a chart from a chart repository. For example:
helm upgrade app chart_name \
--version 1.0.0 \
--repo https://chart.repo.example.com \
--install --values ./values.yml
This says to find and use version 1.0.0 found at the url defined by --repo

dask-getway on K8s using helm3: Error: failed to install CRD crds/daskclusters.yaml

I'm following the instructions to setup Dask on K8s Cluster. I'm on MacOS, have K8s running on Docker Desktop, kubectl version 1.22.5 and helm version 3.8.0. After adding the repository, downloading default configuration, installing helm chart using command
RELEASE=my-dask-gateway
NAMESPACE=dask-gateway
VERSION=0.9.0
helm upgrade --install \
--namespace $NAMESPACE \
--version $VERSION \
--values path/to/your/config.yaml \
$RELEASE \
dask/dask-gateway
generates following output/error
"dask" already exists with the same configuration, skipping
Hang tight while we grab the latest from your chart repositories...
...Successfully got an update from the "dmwm-bigdata" chart repository
...Successfully got an update from the "dask" chart repository
Update Complete. ⎈Happy Helming!⎈
Release "my-dask-gateway" does not exist. Installing it now.
Error: failed to install CRD crds/daskclusters.yaml: unable to recognize "": no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1beta1"
An older post suggests to either update the manifest or use older version of kubernetes. Does that mean dask is not compatible with recent versions of kubernetes?
Posting community wiki answer for better visibility:
This is fixed in the repo main. You could grab the CRDs from there, or wait for a release, which we are hoping to do soon. Otherwise, yes, you would need an older version of kubernetes for dask-gateway to work.

Istio pilot version mismatch. How to upgrade it?

I have upgraded istio from 1.6.0 to 1.6.8. Everything went without problems.
Verification with kubectl get pods -n default -l istio.io/rev={revision} returns that all pods are running by using 1.6.8, but istioctl version returns
client version: 1.6.8
istiod version: 1.6.8
pilot version: 1.6.0
data plane version: 1.6.8 (12 proxies)
Which indicates that pilot is still running on old version. I'm not able to find any information how to upgrade it without reinstalling whole istio.
There is clean 1.6.0 install
istioctl version
client version: 1.6.8
control plane version: 1.6.0
data plane version: 1.6.0 (3 proxies)
There is 1.6.8 after canary install
istioctl version
client version: 1.6.8
pilot version: 1.6.0
istiod version: 1.6.8
data plane version: 1.6.8 (2 proxies), 1.6.0 (7 proxies)
Why does this happen? Because there are 2 versions working, original and canary.
As mentioned here
It was separated from control plane version into 2 parts: pilot version and istiod version.
Btw, it is istio-ingressgateway which uses 1.6.0 in data plane version. It seems intended to update ingress-gateway
I'm not able to find any information how to upgrade it without reinstalling whole istio.
If I understand correct you're not able to upgrade it with this version, the main issue here is that there is no option to delete old control plane, that's already covered in the 1.7 version.
The same thing happened in this tutorial
Workaround for this would be to install version higher than 1.7, then if you check documentation there are steps to Uninstall old control plane and Uninstall canary control plane.
Additional resources:
https://github.com/istio/istio/issues/18900
https://github.com/istio/istio/issues/23889
https://github.com/istio/istio/issues/23923

How to upgrade helm from 2 to 3 version in jenkinsx installed in okd environment

I want to upgrade helm version from 2 version to 3 version since I am facing "Could not find tiller" issue in while using "helm delete --purge " in JenkinsX.
So upgrade does not depend on tiller and makes my job easy. Please help me to resolve this.
jx step helm build
WARNING: No $CHART_REPOSITORY defined so using the default value of: http://jenkins-x-chartmuseum:8080
Adding missing Helm repo: storage.googleapis.com https://storage.googleapis.com/chartmuseum.jenkins-x.io
Successfully added Helm repository storage.googleapis.com.
Adding missing Helm repo: jenkins-x-chartmuseum http://jenkins-x-chartmuseum:8080
Successfully added Helm repository jenkins-x-chartmuseum.
WARNING: No $CHART_REPOSITORY defined so using the default value of: http://jenkins-x-chartmuseum:8080
Adding missing Helm repo: chartmuseum.jenkins-x.io http://chartmuseum.jenkins-x.io
Successfully added Helm repository chartmuseum.jenkins-x.io.
EXITCODE 0[Pipeline] sh
[preview] Running shell script
+ make delete
helm version
Client: &version.Version{SemVer:"v2.14.3", GitCommit:"0e7f3b6637f7af8fcfddb3d2941fcc7cbebb0085", GitTreeState:"clean"}
Error: could not find tiller
use the command choco upgrade kubernetes-helm
first install chococo/brew then use above for choco cmd or brew upgrade helm.
The latest Helm 3 won't need tiller pod.