Back to Blog
Lesson 53 of the Kubernetes: Kubernetes Concepts & Your First Pod course
KubernetesSeptember 10, 20263 min read

Introduction to Helm: Simplifying Kubernetes Deployment

Stop managing endless YAML files. Learn to use Helm, the Kubernetes package manager, to simplify complex application deployment with reusable charts.

KubernetesHelmDevOpsInfrastructure as CodeDeployment
A rustic sailboat docked in a bustling maritime harbor, showcasing nautical charm.

Previously in this course, we covered Deployments: Declarative Updates and Environment-Specific Configuration. While managing raw YAML manifests works for simple projects, it becomes a maintenance nightmare as your architecture grows. This lesson introduces Helm, the industry-standard package manager for Kubernetes, which allows you to bundle, version, and share your application logic as reusable "Charts."

Why We Need Helm for Packaging

When you manage a complex application, you don't just have a Pod. You have a Service, a Deployment, a ConfigMap, a Secret, and perhaps an Ingress. Managing these as dozens of individual files is error-prone.

Helm solves this by introducing:

  1. Templates: Instead of static YAML, you use placeholders that get filled in during deployment.
  2. Values Files: You separate your configuration (ports, image tags, replicas) from the application structure.
  3. Packaging: You can bundle everything into a single "Chart," making it easy to version and distribute.

Installing Helm

Helm is a binary that runs on your local machine and interacts with your cluster via your existing kubeconfig.

  1. macOS (Homebrew): brew install helm
  2. Linux (Snap): sudo snap install helm --classic
  3. Windows (Chocolatey): choco install kubernetes-helm

Once installed, verify it with:

Bash
helm version

Understanding Charts

A Helm Chart is essentially a folder containing a collection of files that describe a related set of Kubernetes resources. When you "deploy an app" with Helm, you are installing a Release—an instance of a chart combined with a specific set of configuration values.

The structure of a chart looks like this:

  • Chart.yaml: Metadata about the app (version, name).
  • values.yaml: The default configuration values.
  • templates/: A folder containing the actual Kubernetes manifests, but with templating syntax (e.g., {{ .Values.replicaCount }}).

Worked Example: Deploying Nginx

Instead of writing a Deployment and Service by hand, we can use the official stable Nginx chart.

Step 1: Add a Repository Helm repositories are like the "App Store" for Kubernetes.

Bash
helm repo add bitnami https://charts.bitnami.com/bitnami
helm repo update

Step 2: Install the Chart We will install the Nginx chart and name our release my-web-app.

Bash
helm install my-web-app bitnami/nginx

Step 3: Verify the Release Unlike kubectl get pods, which shows you the granular pieces, helm list shows you the high-level application status.

Bash
helm list
kubectl get all -l app.kubernetes.io/instance=my-web-app

Hands-on Exercise

In this exercise, you will override the default configuration of the chart to customize your deployment.

  1. Create a file named my-values.yaml with the following content to increase the replica count:
    YAML
    replicaCount: 3
  2. Upgrade your existing release with these new values:
    Bash
    helm upgrade my-web-app bitnami/nginx -f my-values.yaml
  3. Observe the change: kubectl get pods. You should see three Nginx pods spinning up.
  4. Clean up: helm uninstall my-web-app.

Common Pitfalls

  • Forgetting to update repos: Always run helm repo update before installing; otherwise, you might be trying to install an outdated version of a chart.
  • Mixing Imperative and Declarative: If you manually kubectl edit a resource created by Helm, your changes will be overwritten the next time you run helm upgrade. Always make changes in your values.yaml and run the upgrade.
  • Chart Bloat: Don't put everything into one massive chart. Keep your infrastructure (databases, caches) and your application code in separate, modular charts.

FAQ

Q: Do I still need kubectl if I use Helm? A: Yes. Helm is for managing the lifecycle of your applications. You will still use kubectl for day-to-day debugging, checking logs, and viewing events.

Q: Is a Helm release the same as a Kubernetes Deployment? A: No. A Helm release is a collection of resources (which might include a Deployment, a Service, and a Secret). A Deployment is just one type of resource within that collection.

Recap

Helm allows us to move away from "manual" YAML management toward a package-based workflow. By using Charts, we define our infrastructure as a template, use Values to manage environment differences, and use Releases to track our deployments. You’ve now mastered the basics of installing charts and overriding configurations.

Up next: Managing Releases with Helm — we'll dive deeper into upgrading and rolling back your production deployments.

Similar Posts