Helm Chart Push Plugin


Helm Chart Push Plugin

In this tutorial, we will discuss adding a helm chart to the repository using the helm push plugin. Before that, I need to give a quick introduction to a plugin.

Helm Chart Push Plugin

Helm supports plugin architecture where I can develop my custom plugin and make use of it or a plugin developed by a third party and make use of it. The similar way, there is n number of plugins available. One such plugin is the helm push plugin, and that is available over here.

Install Helm Push Plugin

I can install the helm push plugin with a simple command helm plugin install and the GitHub location or the location where I have the installation files. I can install using Helm plugins.

ashok@waytoeasylearn:~/helm_repo_demo$ helm plugin install https://github.com/chartmuseum/helm-push.git
Downloading and installing helm-push v0.9.0 …
https://github.com/chartmuseum/helm-push/releases/download/v0.9.0/helm-push_0.9.0_linux_amd64.tar.gz
Installed plugin: push

Now I can use the command helm plugin list. That’s going to list the plugins installed as a part of this specific helm installation.

ashok@waytoeasylearn:~/helm_repo_demo$ helm plugin list
NAME    VERSION DESCRIPTION                      
push    0.9.0   Push chart package to ChartMuseum

So I do have a push plugin that is going to push the chart package into the ChartMuseum. Now let me go ahead and create a new chart and push the chart using the helm push plugin.

ashok@waytoeasylearn:~/helm_repo_demo$ helm create helmpushdemo
Creating helmpushdemo

Now we do have this chart. Let me get into the chart and update the Chart.yaml file.

ashok@waytoeasylearn:~/helm_repo_demo/helmpushdemo$ cat Chart.yaml 
apiVersion: v2
name: helmpushdemo
description: Helm push plugin demo 
type: application
version: 0.1.0
appVersion: "1.16.0"

Now, let me go ahead and package this Chart.

ashok@waytoeasylearn:~/helm_repo_demo$ helm package helmpushdemo/
Successfully packaged chart and saved it to: /home/ashok/helm_repo_demo/helmpushdemo-0.1.0.tgz

So that’s going to provide me the packaged charts. I can use this package chart, or I can directly use the directory as well. So I can use the command helm. I will use the helm push command.

ashok@waytoeasylearn:~/helm_repo_demo$ helm push helmpushdemo/ mychartmuseumrepo
Pushing helmpushdemo-0.1.0.tgz to mychartmuseumrepo…
Done.

So that’s going to create the zipped content automatically and push it into the repository. Now I can do an update and check the list of charts available within the repository.

ashok@waytoeasylearn:~/helm_repo_demo$ helm repo update
Hang tight while we grab the latest from your chart repositories…
…Successfully got an update from the "mychartmuseumrepo" chart repository
…Successfully got an update from the "stable" chart repository
Update Complete. ⎈Happy Helming!⎈


ashok@waytoeasylearn:~/helm_repo_demo$ helm search repo mychartmuseumrepo -l
NAME                            CHART VERSION   APP VERSION     DESCRIPTION                                 
mychartmuseumrepo/helmpushdemo  0.1.0           1.16.0          Helm push plugin demo                       
mychartmuseumrepo/myrepo        0.1.0           1.16.0          My another helm chart                       
mychartmuseumrepo/repotest      0.1.1           1.16.0          Repo demo in helm using ChartMuseum to 0.1.1
mychartmuseumrepo/repotest      0.1.0           1.16.0          Repo demo in helm using ChartMuseum   

So the advantage of using the push is directly I can mention the chart folder and do a push. I don’t need to do the packaging, do the package and move the files, or use the curl and pass the packaged chart files using the data binary option into the chart museum using REST API.

So there are multiple ways, and these are all different options where I can push the charts into the repository that is the chart museum repository.

Helm Chart Push Plugin
Scroll to top