Install Helm Chart
In this tutorial, we are going to discuss about how to install a helm chart once the repository is configured with the client.
In our installation, we do have the stable repository. I can list the repositories available using following command
$ helm repo list NAME URL stable https://charts.helm.sh/stable
So I do have one repository that is stable and this is the URL from where it is going to pick the charts and this URL is a constant one.
Update helm repository
Now, let me go ahead and update this particular repository so that any future charts available as a part of this particular repository will get added and get cached within this particular client location.
$ helm repo update Hang tight while we grab the latest from your chart repositories… …Successfully got an update from the "stable" chart repository Update Complete. ⎈Happy Helming!⎈
So it’s going to be called the latest information, and update the cache. All the charts are latest one now.
Now I can go ahead and search for the repository say mysql, helm search repo stable/mysql So I do have the chart and that’s going to use the version 5.7.30 of MySQL.
$ helm search repo stable/mysql NAME CHART VERSION APP VERSION DESCRIPTION stable/mysql 1.6.9 5.7.30 DEPRECATED - Fast, reliable, scalable, and easy… stable/mysqldump 2.6.2 2.4.1 DEPRECATED! - A Helm chart to help backup MySQL…
Let me go ahead and do the installation of this particular latest version. In case if I wanted any specific version, I can go ahead and do the installation.
So to get started quickly I’m going to use the stable and latest version.
$ helm install stable/mysql --generate-name
In the above command, I requested helm to generate a name for this particular installation. Now The installation is done.
Above command also provide the nodes in terms of how to access the MySQL that is getting deployed within the Kubernetes cluster and how I can test this particular MySQL installation.
Please not that in the same machine I do have the Kubernetes client installation that is kubectl. I can check the entities that got deployed as a part of this specific cluster using following command.
$ kubectl get all
Please make yourself comfortable with the basics of Kubernetes commands. In case, if you wanted a revision, you can verify the tutorials I have posted related to Kubernetes here.
So this particular chart deployed a POD and the service mysql. And a deployment, so automatically it configured the replica set deployment, service and the POD.
For the time being Let’s not worry about this particular details from where these details are configured and how the details will be provided to the Kubernetes.
Install helm using our own name
The same way let me go ahead and do another installation helm install stable/airflow and let me give a name to it, myairflow.
In the earlier command we asked the helm to generate a name, this time I’m giving my own name for this particular chart.
$ helm install myairflow stable/airflow
For the time being, let’s not worry about this particular chart, what it does and get into the details of this particular chart.
So it’s going to provide information on how this particular entity is getting deployed within the cluster and how to access them.
I can get the details about these PODs and services using the kubectl get all command. So all the required PODs Services, deployment, replica set everything got deployed and all the required information will be available.
So basically, the helm charts, it’s going to facilitate deploying various components of Kubernetes. And in one single go, using a single command, we can deploy the entire infrastructure that is required for the application to be up and running within Kubernetes.
I can list what are all the charts that got deployed by using following command
$ helm ls
Here we have 2 charts myairflow, what’s the version, what is the revision currently one revision and the application version. Those information’s will be available.
Now in case if I wanted to delete any specific chart, I can go ahead and do that. Let me delete one helm that i installed previously
$ helm uninstall myairflow
So all the entities related to this particular chart will be removed from the Kubernetes cluster as well.
So in a quick summary, we have seen how to import the repositories, how to verify the charts within the repository and use a chart and do a quick release into the Kubernetes cluster using the helm install command.
Again, let me remind you all this is a quick introduction, we are going to have detailed discussion on each and every command And their syntax in the future tutorials.