How to install a particular version of helm?

Viewed 4347

I am installing helm through a script which uses these commands to install the latest version -

curl -fsSL -o get_helm.sh https://raw.githubusercontent.com/helm/helm/master/scripts/get-helm-3.2.0
chmod 700 get_helm.sh
./get_helm.sh

however , i don't want it to install the latest versions always. how can i install the version v3.2.4 always?

2 Answers

You can find all the versions of helm binaries on Helm Releases page

If you want to install v3.2.4

$ wget https://get.helm.sh/helm-v3.2.4-linux-amd64.tar.gz
$ tar -zxvf helm-v3.2.4-linux-amd64.tar.gz
$ sudo mv linux-amd64/helm /usr/local/bin/helm
$ helm version
version.BuildInfo{Version:"v3.2.4", GitCommit:"0ad800ef43d3b826f31a5ad8dfbb4fe05d143688", GitTreeState:"clean", GoVersion:"go1.13.12"}

Documentation

It is possible to use the DESIRED_VERSION environment variable to specify the version (by github tag) that should be installed by the get_helm.sh script.

curl -fsSL -o get_helm.sh \
https://raw.githubusercontent.com/helm/helm/master/scripts/get-helm-3
chmod 700 get_helm.sh
DESIRED_VERSION=v3.2.4 ./get_helm.sh
helm version

console output:

Helm v3.2.4 is available. Changing from version v3.5.0.
Downloading https://get.helm.sh/helm-v3.2.4-linux-amd64.tar.gz
Verifying checksum... Done.
Preparing to install helm into /usr/local/bin
helm installed into /usr/local/bin/helm
...
version.BuildInfo{Version:"v3.2.4", 
GitCommit:"0ad800ef43d3b826f31a5ad8dfbb4fe05d143688",
GitTreeState:"clean", GoVersion:"go1.13.12"}
Related