DevOps

ArgoCD Helm Chart Install Applications

Master the art of Kubernetes application deployment using ArgoCD Helm charts with this comprehensive guide, covering setup, management

Argo CD, a GitOps continuous delivery tool, and Helm, can both work together to help admins to simplify the deployment and management process for Kubernetes clusters. We’ll explore ArgoCD helm chart install and how to deploy an application.

What Is Argo CD?

You may have heard about Argo CD. What is it exactly? Argo CD is a GitOps CD tool that simplifies the whole process you need to go through for the deployment process of apps into your Kubernetes cluster. Argo CD uses Git as the single source of truth, and then allows you to monitor the Git repo for changes. If changes are detected it will proactively remediate your Kubernetes cluster apps to line them up with the changes in the Git repo.

What is Helm?

Helm simplifies installing apps in your Kubernetes cluster. Helm allows you to define and install even the most complex Kubernetes applications using a system of charts. Think of it like the package managers that we use in our Linux distros like Ubuntu. You can type a simple apt install command to install a package. Helm does the same for Kubernetes.

How to Install Helm

Let’s look at how to install helm in your environment.

  1. First you will need to download the Helm release that you want to use from the official releases page and get the version you need for your platform, i.e. Windows, macOS, Linux.

  2. Unzip the downloaded file and get access to the helm binary file

    • For macOS and Linux users you can run the command that follows below:

      tar -zxvf helm-v3.x.x-linux-amd64.tar.gz
    • For Windows: Use something like 7-Zip or WinRAR to extract the archive and get access to the file you need

  3. Move the helm binary to your system’s PATH:

    • For macOS and Linux:

      sudo mv linux-amd64/helm /usr/local/bin/helm
    • For Windows: Move the helm.exe binary to a directory in your system’s PATH

  4. Verify the installation: Verify you can run the helm app:

    helm version

Installing an NGINX Helm Chart

Nginx is a simple app project that we can install with helm to get a feel for how to use it to install apps inside a Kubernetes cluster. Note the steps below:

  1. Add the Bitnami Helm repository

    helm repo add bitnami https://charts.bitnami.com/bitnami
  2. Update your Helm repositories:

    helm repo update
  3. Install the NGINX Helm chart: With the Bitnami repository added and updated:

    helm install <release-name> bitnami/nginx
  4. Verify the deployment:

    kubectl get pods

    Next, check the details of the created service by running:

    kubectl get svc

ArgoCD to Deploy Helm Charts

The Argo CD application controller continuously monitors the Git repository and the target Kubernetes environment to make sure that the actual and desired state of the application always match. When difference exist between the cluster and the desired stat exist, Argo CD initiates sync operations.

How do you install ArgoCD?

First, ensure that you have the necessary prerequisites, such as a Kubernetes cluster and the kubectl command-line tool. Next, use the following command to install Argo CD:

kubectl create namespace argocd kubectl apply -n argocd -f https://raw.githubusercontent.com/argoproj/argo-cd/stable/manifests/install.yaml

Installing ArgoCD using Kubeapps

You can also use an application like Kubeapps to install ArgoCD from the catalog.

All of the pods are now running. Note the following installation notes:

CHART NAME: argo-cd
CHART VERSION: 4.6.3
APP VERSION: 2.6.7

** Please be patient while the chart is being deployed **

Access your Argo CD installation:
Execute the following commands:
kubectl port-forward --namespace default svc/argo-cd-server 8080:80 &
export URL=http://127.0.0.1:8080/
echo "Argo CD URL: http://127.0.0.1:8080/"

Execute the following commands to obtain the Argo CD credentials:
echo "Username: "admin""
echo "Password: $(kubectl -n default get secret argocd-secret -o jsonpath="{.data.clearPassword}" | base64 -d)"

Ingress or LoadBalancer

If you are using an ingress controller like NGINX or Traefik, you can setup your ingress routes to access ArgoCD which doesn’t expose external addresses by default as it is setup for ClusterIP.

However, you can also change the service to type LoadBalancer by patching the service like so. Be sure to replace your namespace and loadBalancerIP with the correct values.

kubectl patch service argocd-argo-cd-server -n mynamespace --patch '{ "spec": { "type": "LoadBalancer", "loadBalancerIP": "172.16.5.207" } }'

Create an Application in Argo CD Defined By a Helm Chart

To create an application in Argo CD using a Helm chart, follow these steps:

  1. Access the Argo CD UI and log in using the provided credentials.

  2. Click the “New App” button.

3. Provide the necessary information for your application, such as the application name, project, and target namespace.

4. Under the “Source” section, select “Helm” as the chart type and provide the Helm repository URL containing the desired chart.

5. Configure the required Helm values and repository credentials, if necessary.

6. Click “Create” to create the application.

Wrapping up

Argo CD is a great tool for using GitOps for deploying and managing Kubernetes applications. ArgoCD Helm chart and GitOps principles allow you to tackle the task of deploying and managing your Kubernetes applications. It makes sure your apps look like you want them to look in your Kubernetes clusters.

Subscribe to VirtualizationHowto via Email 🔔

Enter your email address to subscribe to this blog and receive notifications of new posts by email.



Brandon Lee

Brandon Lee is the Senior Writer, Engineer and owner at Virtualizationhowto.com, and a 7-time VMware vExpert, with over two decades of experience in Information Technology. Having worked for numerous Fortune 500 companies as well as in various industries, He has extensive experience in various IT segments and is a strong advocate for open source technologies. Brandon holds many industry certifications, loves the outdoors and spending time with family. Also, he goes through the effort of testing and troubleshooting issues, so you don't have to.

Related Articles

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.