09 - Helm & Package Management
Why this matters
Real applications aren't one YAML file — they're dozens, parameterized per environment. Helm is the de facto package manager for Kubernetes; almost every prod cluster uses it or something like it (Kustomize is the other major option — know both).
Read this first — Definitions & Explanations
Helm
The common package manager for Kubernetes. It templates YAML and installs it as a versioned release.
Chart
A package of templates + default values that describes an application (Deployments, Services, etc.).
values.yaml
Configuration knobs for a chart (image tag, replica count, ingress host). You override values per environment.
Release
An installed instance of a chart in a cluster/namespace (helm install my-app ./chart).
helm upgrade / rollback
- upgrade: apply a new chart version or values
- rollback: return a release to a previous revision
Repository
A place that hosts charts (helm repo add ...).
Why Helm helps
Keeps complex apps maintainable, repeatable, and parameterized instead of copying raw YAML forever.
Official docs (read for detail)
- Helm Docs
- Helm Charts Guide
- Chart Best Practices
- Kubernetes Package Management overview (objects Helm renders)
Key Concepts
- Chart = templated collection of manifests +
values.yaml - Release = a deployed instance of a chart (can install same chart multiple times)
helm install/upgrade/rollback/uninstall- Chart repositories,
Chart.yaml, dependencies (subcharts) - Templating:
{{ .Values.x }},{{ include }},{{ if }}, ranges - Helm vs Kustomize: templating engine vs patch-based overlays — know the tradeoffs
helm diffplugin for safe upgrades,--dry-run/--debug
YouTube search terms
- "Helm charts explained Kubernetes"
- "Helm vs Kustomize"
- "Writing your first Helm chart tutorial"
Hands-on lab (on prod-sim)
# Install something real via Helm
helm repo add bitnami https://charts.bitnami.com/bitnami
helm repo update
helm install my-nginx bitnami/nginx --set replicaCount=2
helm list
helm status my-nginx
# Upgrade and rollback
helm upgrade my-nginx bitnami/nginx --set replicaCount=4
helm history my-nginx
helm rollback my-nginx 1
# Write your own minimal chart
helm create mychart
# edit mychart/values.yaml: change replicaCount to 2, image.repository to nginx
helm install test-release ./mychart --dry-run --debug # render without applying
helm install test-release ./mychart
kubectl get deployments -l app.kubernetes.io/instance=test-release
helm uninstall test-release
helm uninstall my-nginx
Notes
(fill in your own words after watching + labbing)