Deep Dives for helm
Introduction
Deploying an application on Kubernetes usually means writing and managing several YAML files — Deployments, Services, ConfigMaps, Secrets, Ingress, and more. As an application grows, keeping all these files consistent across environments (dev, staging, production) becomes messy and error-prone.
Helm solves this problem. It is the official package manager for Kubernetes — think of it as 'apt' or 'npm', but for Kubernetes applications. Helm packages all your YAML files into a single reusable unit called a Chart, which can be installed, upgraded, or removed with one command.
Tips : If Kubernetes is the operating system, Helm is the app store. Instead of manually writing dozens of YAML files, you just run 'helm install' and your entire application — with all its resources — is deployed in seconds. In this lesson, you'll learn the 4 core building blocks of Helm:
• Helm Charts — the package format that bundles all Kubernetes resources
• Values.yaml — the configuration file that customizes a chart
• Templating — how Helm generates dynamic YAML using variables
• Releases — a tracked, versioned deployment of a chart
Before anything else, install the Helm CLI on your machine:
$ curl https://raw.githubusercontent.com/helm/helm/main/scripts/get-helm-3 | bash
$ helm version
version.BuildInfo{Version:"v3.15.0", GitCommit:"...", GoVersion:"go1.22"}
Helm Charts
A Helm Chart is a collection of files that describe a related set of Kubernetes resources. A single chart might deploy something as simple as a Pod, or as complex as a full application stack with a Deployment, Service, Ingress, and database.
Charts are reusable — the same chart can be installed multiple times, with different configurations, across different environments or even different clusters.
Typical Chart Structure
mychart/
Chart.yaml
# Metadata: name, version, description
values.yaml
# Default configuration values
charts/
# Any dependency charts
templates/
# Kubernetes YAML templates
deployment.yaml
service.yaml
ingress.yaml
_helpers.tpl
# Reusable template snippets
Hands-On:
Create Your First Chart Helm can scaffold a starter chart for you automatically.
$ helm create mychart
Creating mychart
$ ls mychart
Chart.yaml charts templates values.yaml
You now have a fully working chart with sample Deployment and Service templates already wired up — ready to customize.
Hands-On: Install a Chart from a Public Repository You don't always need to write your own chart. Thousands of ready-made charts exist in public repositories:
$ helm repo add bitnami https://charts.bitnami.com/bitnami
$ helm repo update
$ helm install my-nginx bitnami/nginx
NAME: my-nginx
STATUS: deployed
REVISION: 1
2. Values.yaml
What is Values.yaml? values.yaml is the default configuration file for a chart. It defines variables — like image name, replica count, resource limits, or port numbers — that templates use to generate the final Kubernetes YAML.
This is what makes charts reusable: the same chart can behave differently just by changing the values passed to it, without touching the underlying templates.
Example values.yaml
replicaCount: 2
image:
repository: nginx
tag: "1.25"
pullPolicy: IfNotPresent
service:
type: ClusterIP
port: 80
resources:
limits:
cpu: 200m
memory: 256Mi
Hands-On: Override Values at Install Time
You can override any default value directly from the command line using --set:
$ helm install my-nginx bitnami/nginx --set replicaCount=4,service.type=LoadBalancer
Or, for larger changes, create your own custom-values.yaml file and pass it in with -f:
$ helm install my-nginx bitnami/nginx -f custom-values.yaml
3.Templating
What is Templating? Helm templates are Kubernetes YAML files with placeholders written in Go template syntax. Instead of hardcoding values, templates pull data from values.yaml — so the same template can generate different output for different configurations.
Example Template (deployment.yaml)
apiVersion: apps/v1
kind: Deployment
metadata:
name: {{ .Release.Name }}-deployment
spec:
replicas: {{ .Values.replicaCount }}
template:
spec:
containers:
- name: app
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
ports:
- containerPort: {{ .Values.service.port }}
Here, {{ .Values.replicaCount }} is replaced with whatever value is set in values.yaml (or overridden with - set). {{ .Release.Name }} is automatically filled in with the release name you choose at install time.
Hands-On: Preview Generated YAML Before Installing Always check what YAML a template will actually produce before applying it to a cluster:
$ helm template my-nginx bitnami/nginx --set replicaCount=3
# Prints the fully rendered Kubernetes YAML to your terminal
You can also do a full dry run against the cluster, without actually creating anything:
$ helm install my-nginx bitnami/nginx --dry-run --debug
4. Releases
Every time you run 'helm install', Helm creates a Release — a specific, tracked instance of a chart running in your cluster, along with the exact configuration used to deploy it.
Every 'helm upgrade' creates a new revision of that same release, so you always have a history you can go back to.
Hands-On: Manage a Release
List all releases currently running in the cluster:
$ helm list
NAME NAMESPACE REVISION STATUS CHART APP VERSION
my-nginx default 1 deployed nginx-15.5.0 1.25.0
Upgrade a release with new values (e.g. scaling replicas):
$ helm upgrade my-nginx bitnami/nginx --set replicaCount=5
Release "my-nginx" has been upgraded. Happy Helming!
REVISION: 2
Check the full revision history of a release:
$ helm history my-nginx
REVISION STATUS CHART DESCRIPTION
1 superseded nginx-15.5.0 Install complete
2 deployed nginx-15.5.0 Upgrade complete
Made a mistake? Roll back to any previous revision instantly:
$ helm rollback my-nginx 1
Rollback was a success! Happy Helming!
Remove a release completely when you're done with it:
$ helm uninstall my-nginx
release "my-nginx" uninstalled
Helm Concepts — At a Glance Here's a quick side-by-side comparison of all four concepts:
A quick real-world analogy:
• Chart = a recipe
• Values.yaml = the ingredient list you can customize (more salt, less sugar)
• Templating = the cooking instructions that adapt based on the ingredients chosen
• Release = the actual dish served on your table, with a record of every time you re-cooked it.
Practical Checklist & Troubleshooting Commands
you'll actually reach for once Helm is part of your daily workflow:
1. Validate a chart's syntax before installing:
$ helm lint mychart
2. See exactly what YAML will be generated:
$ helm template mychart
3.Check the status and details of a running release:
$ helm status my-nginx
4.Get the values currently in use for a release:
$ helm get values my-nginx
5.Clean up a chart you were just testing:
$ helm uninstall my-nginx
Common Issues You'll Run Into
Why Helm Matters in Production
As applications grow past a handful of YAML files, managing raw manifests by hand becomes unsustainable. Helm is the standard tool DevOps teams use to keep deployments consistent, repeatable, and safe to change.
• One chart can be reused across dev, staging, and production with different values • Every deployment is versioned — mistakes can be rolled back in seconds
• Thousands of production-ready charts already exist for popular software (databases, monitoring, ingress controllers)
• Teams stop copy-pasting YAML and start sharing standardized, tested charts.
About the author
- Hi there! I'm a passionate AWS DevOps Engineer with 2+ years of experience in building and managing scalable, reliable, and secure cloud infrastructure. I'm excited to share my knowledge and insights through this blog. Here, you'll find articles on: AWS Services: Deep dives into core AWS services like EC2, S3, Lambda, and more. DevOps Practices: Best practices for CI/CD, infrastructure as code, and automation. Security: Tips and tricks for securing your AWS environments. Serverless Computing: Building and deploying serverless applications. Troubleshooting: Common issues and solutions in AWS. I'm always eager to learn and grow, and I hope this blog can be a valuable resource for fellow DevOps enthusiasts. Feel free to connect with me on [LinkedIn/Twitter] or leave a comment below!
Comments
Join the discussionNo comments yet. Be the first to comment.
