Free lesson · CKAD Prep Program · Module 3: Application deployment
Install, Upgrade and Roll Back with Helm
Helm packages Kubernetes manifests into versioned, configurable releases. The exam angle is operational: install with values, upgrade deliberately, retreat by number, and never template-blind.
13 min reading
Objectives
- Explain what a chart, release and values file each own
- Install a release with custom values without editing templates
- Upgrade a release and roll it back by revision number
- Render templates locally to read what Helm would install
Why this matters
Third-party software on Kubernetes ships as charts: databases, ingress controllers, monitoring stacks. Installing them by hand-copying manifests means owning upgrades forever. Helm owns the lifecycle instead: one release name, numbered revisions, values that separate your configuration from the chart author's templates.
Concepts
A chart is the package: templates plus default values plus metadata. A release is an installed instance: same chart installed twice with different names makes two independent releases. Values files override defaults without touching templates, which keeps upgrades clean: your choices live in your file, the chart stays upstream.
helm install <release> <chart> -f my-values.yaml creates revision 1. helm upgrade <release> <chart> -f my-values.yaml creates revision 2 with a three-way merge of old values, new values and live state. helm rollback <release> <revision> returns to any recorded revision. helm template renders manifests locally with no cluster contact: read before you install, always.
Namespaces matter: --create-namespace -n staging scopes the release, and deleting a namespace removes its releases with it. Values precedence (CLI --set beats files beat chart defaults) decides the final manifest; when output surprises you, check the precedence chain first.
Worked example
A demo database, configured, upgraded, retreated:
helm repo add bitnami https://charts.bitnami.com/bitnami
helm install demo-db bitnami/postgresql \
-n demo --create-namespace \
-f demo-values.yaml
helm list -n demo # revision 1, deployed
helm template bitnami/postgresql -f demo-values.yaml | head -40
# change one value, upgrade, regret, retreat
helm upgrade demo-db bitnami/postgresql -n demo -f demo-values-v2.yaml
helm history demo-db -n demo
helm rollback demo-db 1 -n demo
helm status demo-db -n demo # back on revision 1, deployedHistory plus status is the receipt chain: every change numbered, every state named.
Exam notes
Forgetting -n installs into default and orphans the release from your mental model: always name the namespace. --set quoting bites with dots and commas in values: prefer files for anything complex. And rollback returns manifests, not data: a migrated database does not un-migrate, which no package manager can fix for you.
Quick check
A 4-question self-check. Your answers stay on your device, are never stored or sent. Only a passing score (for example 3 of 4) is saved, and only to unlock lesson progress: at least 3 correct is required before a lesson counts as complete. It never counts toward any certification assessment.
Lesson feedback
No published feedback yet.
Log in and complete the lesson to leave feedback.
Exercise
Install any chart into a fresh namespace with a values file you wrote (two changed values), upgrade one value, then roll back to revision 1. Record all four commands plus the history output that proves the revision walk.
Pass criteria
Install names namespace plus values file; upgrade changes exactly one value; rollback targets revision 1; history output shows 1, 2, rollback with deployed status.