Helm: Kubernetes package manager
Tags: kubernetes, helm, charts, devops
Published: 2021-09-25 06:29:29

## What is Helm ??

Helm is the first application package manager running atop Kubernetes. It allows describing the application structure through convenient helm-charts and managing it with simple commands. 
 
Helm provides the same basic feature set as many of the package managers you may already be familiar with, such as Debian’s apt, or Python’s pip.

Helm can:
- Install software.
- Automatically install software dependencies.
- Upgrade software.
- Configure software deployments.
- Fetch software packages from repositories.

Helm helps you to manage Kubernetes applications. Helm Charts helps you to install, manage and upgrade even the most complex applications. Helm is a third part tool that manages K8s package.

Package in Kubernetes is known as Charts. Either we can download Charts from some repository or we can create our own custom chart. 

### In this article we will create own custom chart.

For this Interesting We'll use AWS Cloud for setting up Kubernetes Master and Kubernetes Slave. If you are interested in setting up this cluster you can read one of my another [blog](https://dev.to/piyushbagani15/configuring-kubernetes-multinode-cluster-over-aws-using-ansible-2fhe). 
### Here We'll integrate Jenkins with Helm.
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/e502992lxlpfdf4nv5p0.png)

### Installing Helm

We have to install Helm in client side. Most common and preferred way is to install it from binary.
Here you will find the link for downloading the binary of Helm Version 3
https://get.helm.sh/helm-v3.5.2-linux-amd64.tar.gz
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/9xcl4jm6ofm81nnfwna6.PNG)
Copy the directory linux-amd64/helm to /usr/bin/
We can check the version of Helm by the below command.

    helm version

After setting up K8s Cluster let’s start creating our own custom charts. Create a workspace where we will create Charts.
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/57yi3m50h8dqi53s2il9.PNG)
Configuration file for the chart is Chart.yaml. We have to create Chart.yaml and it is compulsory to have capital ‘C’ in Chart.yaml.

Content inside Chart.yaml is as follows
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/57yi3m50h8dqi53s2il9.PNG)

Create template directory inside your workspace.
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/elaw72cqvg9zitk9errp.PNG)

Next we can create deployment.yaml by the command provided below. In this deployment code we are using the Jenkins image. The yaml code for deployment.yaml will look like as below
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/pycv55ufw0h1p5bb9nqv.PNG)

Now Let's install the helm chart.
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ibe9e15o8v4vpfbx7utc.PNG)
Let’s check whether the pods are running or not? and also we can check is 'none' services running apart from kubernetes of type Cluster-Ip.
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/sq54tuph97nccuvws8z8.PNG)
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/71erbwxmzmc7fwfdy6sq.PNG)

Now we will expose the Jenkins server and the service.yaml is as below.
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/x3xitry1m6o9hy64w9an.PNG)
Let’s see the new services has launched or not?
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/lrnn21rv3jxyi6kjzk4v.PNG)
Now we can check that our Jenkins server is publicly accessible or not. By hitting to the "http://public_ip_address:exposed_port"
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/fyr7ckuw6x9sy2jhjsvl.PNG)
For getting the password of running Jenkins server, we will do login inside the pod and view the file that contains the Jenkins server password.
Location of the password file is /var/jenkins_home/secrets/initialAdminPassword
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/1yvri1zs6uwwo2he3e3c.PNG)
Now from the above file we can copy the password and paste it in the above displayed page.

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/6h6xzoxx15nwi6ctubxt.PNG)

Voila, We did it, Now further you can configure it according to the requirements.

### That’s all for now. 
### Thanks for reading the Article.
### Happy Helming!