By the end you'll know
- What Helm is for, and how charts, values, releases and revisions fit together
- How to install, upgrade, roll back, render and remove a chart
- Why
helm upgradecan quietly drop a setting, and how to stop it - How Kustomize builds each environment from a base and an overlay, with no templates
- What a CRD is, how to make one, and what it does and doesn't do
- Where the container runtime, network and storage interfaces fit
Before you start
- You need: the cluster from Lesson 2, all nodes
Ready. - Internet access on cp1: Helm and a chart are downloaded.
- The output below is from real runs on November 27, 2026, in New York, on an Apple silicon Mac.
These three were added to the exam's Cluster Architecture domain (25%) in 2025, so older study guides often skip them. They're also how most software really gets into clusters.
Helm: a package manager for Kubernetes
Helm does three jobs:
- Packaging: all the YAML an app needs, bundled into one chart and installed as a unit.
- Templating: the chart's YAML has gaps, filled in per install from values, so one chart works anywhere.
- Release history: every install and upgrade is a numbered revision, which you can roll back to.
| Word | Means |
|---|---|
| Chart | The package: Chart.yaml (name and versions), values.yaml (default settings) and templates/ (YAML with gaps) |
| Values | The settings that fill the gaps |
| Release | One installed copy of a chart, with a name you choose |
| Revision | One version of a release: install is 1, each upgrade or rollback adds one |
| Manifest | The finished YAML, gaps filled, that Helm sends to the API server |
Helm is a client, like kubectl. It reads the same ~/.kube/config and talks to the API server. Nothing of Helm's runs in the cluster.
Install Helm
(cp1)
HELM_VER=v4.3.1
ARCH=$(dpkg --print-architecture)
cd /tmp
curl -fsSLO https://get.helm.sh/helm-${HELM_VER}-linux-${ARCH}.tar.gz
curl -fsSLO https://get.helm.sh/helm-${HELM_VER}-linux-${ARCH}.tar.gz.sha256sum
sha256sum -c helm-${HELM_VER}-linux-${ARCH}.tar.gz.sha256sum
get.helm.sh: Helm's official download host. The.sha256sumfile holds the expected checksum.
helm-v4.3.1-linux-arm64.tar.gz: OK
tar -xzf helm-${HELM_VER}-linux-${ARCH}.tar.gz
sudo install linux-${ARCH}/helm /usr/local/bin/
helm version
cd ~
version.BuildInfo{Version:"v4.3.1", GitCommit:"c0d08d0d6d9424d4a14febb5e8a3e51b0dd00dff", GitTreeState:"clean", GoVersion:"go1.27.2", KubeClientVersion:"v1.37"}
KubeClientVersion:"v1.37": Helm carries kubectl's client code, matched to your cluster. On a machine you didn't set up, check with helm version before installing it.
Find a chart and look before installing
We'll use podinfo, a small demo web app made for exactly this kind of practice:
helm repo add podinfo https://stefanprodan.github.io/podinfo
helm repo update
helm search repo podinfo
helm show values podinfo/podinfo | head -25
repo add NAME URL: registers a chart repository under a nickname you choose, like adding a source to apt.repo update: downloads the repository's current chart list.podinfo/podinfo:REPO/CHART. Your nickname for the repository, then the chart's name inside it. One-chart projects often name both the same, likeingress-nginx/ingress-nginx; a repo with many charts reads likebitnami/redis.show values: the chart's defaults, every one of which you can override.
# Default values for podinfo.
replicaCount: 1
logLevel: info
...
image:
repository: ghcr.io/stefanprodan/podinfo
tag: 6.17.0
pullPolicy: IfNotPresent
...
ui:
color: "#34577c"
message: ""
Install
k create ns helm-lab
helm install web podinfo/podinfo -n helm-lab --set replicaCount=2
helm list -n helm-lab
helm install RELEASE CHART:webis the release name. Install the same chart again under another name and you get a second, separate copy.--set replicaCount=2: overrides one default.
NAME: web
LAST DEPLOYED: Fri Nov 27 18:25:05 2026
NAMESPACE: helm-lab
STATUS: deployed
REVISION: 1
DESCRIPTION: Install complete
...
NAME NAMESPACE REVISION UPDATED STATUS CHART APP VERSION
web helm-lab 1 2026-11-27 18:25:05.045717569 +0000 UTC deployed podinfo-6.17.0 6.17.0
CHART: podinfo-6.17.0is the chart's own version.APP VERSION: 6.17.0is the app inside it. They match here, but often don't: a chart can get a template fix while the app stays the same.- The pods are named
web-podinfo-...:RELEASE-CHART, so two installs never clash.
Upgrade with a values file
--set works for one or two values. For more, use a file:
cat > web-values.yaml <<'EOF'
replicaCount: 3
ui:
message: "Hello from revision 2"
color: "#2e7d32"
EOF
helm upgrade web podinfo/podinfo -n helm-lab -f web-values.yaml
k get pods -n helm-lab
helm upgrade RELEASE CHART: changes an installed release.-fsupplies values from a file.
Release "web" has been upgraded. Happy Helming!
...
REVISION: 2
DESCRIPTION: Upgrade complete
...
NAME READY STATUS RESTARTS AGE
web-podinfo-59fbfc5df-6n6vj 0/1 ContainerCreating 0 0s
web-podinfo-59fbfc5df-bcz77 0/1 ContainerCreating 0 0s
web-podinfo-864975cbdc-kmtxh 0/1 Terminating 0 0s
web-podinfo-864975cbdc-pwghp 1/1 Running 0 92m
web-podinfo-864975cbdc-z5fgv 1/1 Running 0 92m
Caught mid-rollout: the new ReplicaSet (59fbfc5df) starting while the old one (864975cbdc) still serves. A minute later, three new pods were running.
Where did the first install's value go?
helm get values web -n helm-lab --revision 2
USER-SUPPLIED VALUES:
replicaCount: 3
ui:
color: '#2e7d32'
message: Hello from revision 2
Revision 2 kept only the file's values. The install's --set replicaCount=2 didn't carry over. It made no difference here, because the file set replicaCount too. But had the file left it out, the upgrade would have quietly dropped the release to the chart's default of one pod.
helm upgrade forgets earlier values
helm upgrade starts from the chart's defaults plus what you pass this time. To keep earlier settings: add --reuse-values (keep the last revision's values and apply yours on top), or save them first with helm get values RELEASE -n NS -o yaml > current.yaml, edit, and pass -f current.yaml.
My first two tries at that command show another trap:
vagrant@cp1:~$ helm get values -n web helm-lab
Error: release: not found
vagrant@cp1:~$ helm get values web -n hem-lab
Error: release: not found
-n is the namespace in Helm too, and the release name is the argument. The first read web as the namespace and helm-lab as the release. The second had a typo in the namespace, and nothing complains about a namespace that doesn't exist when you only read: you just find nothing.
Roll back
helm rollback web 1 -n helm-lab
helm history web -n helm-lab
k get pods -n helm-lab
helm get values web -n helm-lab
Rollback was a success! Happy Helming!
REVISION UPDATED STATUS CHART APP VERSION DESCRIPTION
1 Fri Nov 27 18:25:05 2026 superseded podinfo-6.17.0 6.17.0 Install complete
2 Fri Nov 27 19:57:19 2026 superseded podinfo-6.17.0 6.17.0 Upgrade complete
3 Fri Nov 27 20:06:04 2026 deployed podinfo-6.17.0 6.17.0 Rollback to 1
NAME READY STATUS RESTARTS AGE
web-podinfo-864975cbdc-9ldm4 1/1 Running 0 46s
web-podinfo-864975cbdc-pvqhd 1/1 Running 0 46s
USER-SUPPLIED VALUES:
replicaCount: 2
- A rollback is a new revision, "Rollback to 1". Helm never rewrites history, so you could still roll forward to 2.
- The pods carry revision 1's ReplicaSet hash,
864975cbdc. The rollback restored the exact old pod template, so the Deployment scaled the old ReplicaSet back up instead of building a new one.
Render without installing
helm template web podinfo/podinfo --set replicanCount=2 > podinfo-rendered.yaml
grep "^kind:" podinfo-rendered.yaml
grep -n "replicas:" podinfo-rendered.yaml
grep -n "helm.sh/hook" podinfo-rendered.yaml
helm template: fills the gaps and prints the manifest, touching nothing in the cluster. A task might word this as "render the chart into a file".
kind: Service
kind: Deployment
kind: Pod
kind: Pod
kind: Pod
40: replicas: 1
132: "helm.sh/hook": test-success
...
Two lessons in that output. First, look closely at the command: replicanCount, a typo. Helm accepted it without a word, and the manifest says replicas: 1, the default. Charts generally ignore values they don't know, so after any --set, check the result. Second, the three Pods are the chart's tests (helm.sh/hook: test-success), which only run with helm test. Add --skip-tests to leave them out.
Remove it
vagrant@cp1:~$ helm uninstall web -n helm-lab
release "web" uninstalled
vagrant@cp1:~$ k get all -n helm-lab
No resources found in helm-lab namespace.
Kustomize: patch plain YAML per environment
Kustomize solves the "different settings per environment" problem without templates. You write plain YAML once, the base, and small overlays that change it per environment. It's built into kubectl.
A base
mkdir -p ~/kust/base ~/kust/overlays/prod
cd ~/kust/base
k create deploy shop --image=nginx:alpine $do > deployment.yaml
k create service clusterip shop --tcp=80:80 $do > service.yaml
cat > kustomization.yaml <<'EOF'
resources:
- deployment.yaml
- service.yaml
EOF
k kustomize .
k create service clusterip shop --tcp=80:80: a Service from port 80 to target port 80, with the selectorapp=shop.kustomization.yaml: Kustomize's one required file. Here it lists the files in the base.k kustomize DIR: renders the result without applying it, likehelm template.
A prod overlay
cd ~/kust/overlays/prod
cat > kustomization.yaml <<'EOF'
resources:
- ../../base
namespace: kust-prod
namePrefix: prod-
replicas:
- name: shop
count: 3
images:
- name: nginx
newTag: 1.27-alpine
EOF
k kustomize .
| Base | Prod overlay | |
|---|---|---|
| Names | shop | prod-shop |
| Namespace | none | kust-prod |
| Replicas | 1 | 3 |
| Image | nginx:alpine | nginx:1.27-alpine |
| Labels and selector | app: shop | app: shop, unchanged |
- The base files never changed. A
devoverlay beside this one could use the same base with different settings. - Labels stay the same, so the renamed Service still finds the renamed pods.
namePrefixchanges names, not selectors. replicasandimagesname the base's objects (shop,nginx), not the prefixed names.
vagrant@cp1:~/kust/overlays/prod$ k create ns kust-prod
namespace/kust-prod created
vagrant@cp1:~/kust/overlays/prod$ k apply -k .
service/prod-shop created
deployment.apps/prod-shop created
vagrant@cp1:~/kust/overlays/prod$ k get all -n kust-prod
NAME READY STATUS RESTARTS AGE
pod/prod-shop-55d488c58d-29xwp 1/1 Running 0 14s
pod/prod-shop-55d488c58d-nrqkm 1/1 Running 0 14s
pod/prod-shop-55d488c58d-tck9z 1/1 Running 0 14s
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
service/prod-shop ClusterIP 10.106.123.51 <none> 80/TCP 14s
NAME READY UP-TO-DATE AVAILABLE AGE
deployment.apps/prod-shop 3/3 3 3 14s
k apply -k DIR: renders the kustomization in that folder and applies it, in one step.
Helm and Kustomize, side by side: Helm fills gaps in templates and keeps a release history. Kustomize patches plain YAML and has no history: k apply -k is a smarter k apply -f. Many teams use both, Helm for other people's software and Kustomize for their own.
CRDs: new kinds of objects
A CRD (Custom Resource Definition) teaches the API server a new kind of object. Your cluster already has some:
vagrant@cp1:~$ k get crd | head -5
NAME SCOPE VERSIONS CREATED AT
bgpconfigurations.crd.projectcalico.org Cluster v1(storage) 2026-11-24T03:58:20Z
bgpfilters.crd.projectcalico.org Cluster v1(storage) 2026-11-24T03:58:20Z
bgppeers.crd.projectcalico.org Cluster v1(storage) 2026-11-24T03:58:20Z
blockaffinities.crd.projectcalico.org Cluster v1(storage) 2026-11-24T03:58:20Z
vagrant@cp1:~$ k get crd | wc -l
24
vagrant@cp1:~$ k api-resources | grep -i ippool
ippools crd.projectcalico.org/v1 false IPPool
24 lines is 23 CRDs plus the header: 22 of Calico's, and one more, clusternetworkpolicies.policy.networking.k8s.io, which k get crd | grep -v projectcalico shows. ippools sits in api-resources like any built-in type: group crd.projectcalico.org/v1, not namespaced (false), kind IPPool.
Make your own
cat > backup-crd.yaml <<'EOF'
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
name: backups.lab.example.com
spec:
group: lab.example.com
scope: Namespaced
names:
plural: backups
singular: backup
kind: Backup
shortNames: [bk]
versions:
- name: v1
served: true
storage: true
schema:
openAPIV3Schema:
type: object
properties:
spec:
type: object
properties:
schedule:
type: string
retentionDays:
type: integer
EOF
k apply -f backup-crd.yaml
k api-resources | grep -i backup
metadata.namemust bePLURAL.GROUP.group: the API group, likeappsfor Deployments. Use a domain you control.scope: Namespaced: each object lives in a namespace.Clusterwould make it cluster-wide.names: how you type it, including the short namebk.schema: the allowed fields and types.k explainreads it, and the API server checks objects against it.
customresourcedefinition.apiextensions.k8s.io/backups.lab.example.com created
backups bk lab.example.com/v1 true Backup
Use it like any other object
cat > nightly.yaml <<'EOF'
apiVersion: lab.example.com/v1
kind: Backup
metadata:
name: nightly
namespace: default
spec:
schedule: "0 2 * * *"
retentionDays: 7
EOF
k apply -f nightly.yaml
k get bk
k explain backup.spec
backup.lab.example.com/nightly created
NAME AGE
nightly 0s
GROUP: lab.example.com
KIND: Backup
VERSION: v1
FIELD: spec <Object>
...
FIELDS:
retentionDays <integer>
<no description>
schedule <string>
<no description>
<no description> is because the schema has none. Real CRDs include them, which is what makes k explain useful on them. Now the wrong type, on purpose:
vagrant@cp1:~$ k patch backup nightly --type=merge -p '{"spec":{"retentionDays":"seven"}}'
The Backup "nightly" is invalid: spec.retentionDays: Invalid value: "string": spec.retentionDays in body must be of type integer: "string"
The API server validates custom objects against their schema, just as it validates a pod.
What a CRD doesn't do is anything. nightly is stored and listed, but nothing backs anything up at 2am. To make a custom object act, a controller, often called an operator, watches objects of that kind and does the work. That's how Calico works: its controllers watch its CRDs and configure the network.
Deleting a CRD deletes every object of its kind:
vagrant@cp1:~$ k delete crd backups.lab.example.com
customresourcedefinition.apiextensions.k8s.io "backups.lab.example.com" deleted
vagrant@cp1:~$ k get bk
Error from server (NotFound): Unable to list "lab.example.com/v1, Resource=backups": the server could not find the requested resource (get backups.lab.example.com)
The interfaces Kubernetes plugs into
The curriculum also asks you to understand the three plugin interfaces. You've met all three:
| Interface | Plugs in | On your cluster | Find it with |
|---|---|---|---|
| CRI (Container Runtime Interface) | The program that runs containers | containerd 2.2.1 | k get nodes -o wide, CONTAINER-RUNTIME column |
| CNI (Container Network Interface) | Pod networking | Calico | k get pods -n kube-system, and /etc/cni/net.d/ on a node |
| CSI (Container Storage Interface) | Storage drivers for volumes | None yet: Lesson 11 | k get csidrivers, k get storageclass |
crictl, from Lesson 3, talks to the runtime through the CRI. Calico arrived through the CNI in Lesson 2.
How the drills work
Each drill is a task to do from a blank terminal. Try it first, without looking. Then open "Show the fast way" to compare your commands, and read the notes under them: they cover the part people usually get wrong. Repeat a drill a few days later until you can do it cold, because the exam leaves little time to look things up.
The drills
Install chart podinfo/podinfo as release web in a new namespace apps with 2 replicas, then upgrade it to show the message hello without losing the replica setting.
Show the fast way
helm repo add podinfo https://stefanprodan.github.io/podinfo # if not added yet
k create ns apps
helm install web podinfo/podinfo -n apps --set replicaCount=2
helm upgrade web podinfo/podinfo -n apps --reuse-values --set ui.message=hello
helm get values web -n apps # both values present
helm history web -n apps
Without --reuse-values, the upgrade drops replicaCount=2 and the release falls back to one pod. -n is the namespace; the release name is the argument. Check typos with helm get values: Helm ignores misspelled values silently.
Render chart podinfo/podinfo with 3 replicas into /tmp/podinfo.yaml, without its tests, and without installing anything.
Show the fast way
helm template web podinfo/podinfo --set replicaCount=3 --skip-tests > /tmp/podinfo.yaml
grep "^kind:" /tmp/podinfo.yaml
grep -n "replicas:" /tmp/podinfo.yaml
Check the file: a typo in --set gives the default with no warning. Without --skip-tests, the chart's test Pods are in the file too.
Preview what the kustomization in ~/kust/overlays/prod would create, then apply it.
Show the fast way
k kustomize ~/kust/overlays/prod
k apply -k ~/kust/overlays/prod
k get all -n kust-prod
-k takes a folder with a kustomization.yaml, not a file. k kustomize previews without applying. If the overlay sets a namespace, that namespace must exist first.
Find which custom resource types the cluster has, explain one, and create an object of that type.
Show the fast way
k get crd
k api-resources | grep -i NAME
k explain KIND.spec
k apply -f object.yaml # apiVersion GROUP/VERSION, kind KIND
k get KIND
k api-resources gives the group, version, kind and whether it's namespaced, which is everything the object's YAML header needs. k explain shows the fields the schema allows. Deleting the CRD deletes every object of its kind.
Find out which container runtime and network plugin a cluster uses.
Show the fast way
k get nodes -o wide # CONTAINER-RUNTIME column
k get pods -n kube-system # calico-node, cilium, flannel...
ls /etc/cni/net.d/ # on a node
The CONTAINER-RUNTIME column names the CRI runtime and its version. The network plugin shows up as DaemonSet pods in kube-system, and its config file in /etc/cni/net.d/ on each node.
On exam day
- Use the exact release name, namespace and values the task gives. A release named
podinfoindefaultisn't the releasewebinappsthat the task asked for. helm list -Afinds a release when you don't know its namespace.helm repo listshows which repos are already added.- Upgrading? Keep the old values with
--reuse-values, unless the task gives a full values file. - Verify values after every
--setwithhelm get valuesor by grepping the rendered YAML. - Copy CRD and kustomization YAML from the docs rather than typing it.
Clean up
k delete ns kust-prod helm-lab
rm -rf ~/kust ~/podinfo-rendered.yaml ~/web-values.yaml
k delete nsremoves the Kustomize app and the now-empty Helm namespace. The CRD and its object were deleted in the last step.rm -rfremoves the lab's files:-rfor folders and what's in them,-fto skip prompts.
Keep Helm installed: you'll use it again.
In real life
- Keep values files in git, and always upgrade with
-fthat file. Then nothing depends on remembering past--setflags. - GitOps tools like Argo CD and Flux render Helm charts and Kustomize overlays from git and apply them, so nobody runs
helm upgradeby hand. - Pin chart versions with
--versionin production. "Latest" can change under you. - Operators run many databases and platforms: a PostgreSQL operator, for example, adds a
Postgreskind and handles backups, failover and upgrades for each object you create.
Spot the problem
Work out what's wrong before you read the explanation.
"The upgrade halved our replicas." A release was installed with --set replicaCount=4. Someone runs helm upgrade web repo/chart --set image.tag=2.0, and the app drops to one pod. Why? helm upgrade starts from the chart's defaults plus what's passed now, so replicaCount=4 was forgotten. --reuse-values would have kept it.
"Helm ignored my setting." helm install web podinfo/podinfo --set replicaCont=3 installs fine, with one pod. No error appeared. What happened? A typo in the value's name. Charts ignore values they don't know, so nothing failed. helm get values shows what was really passed; compare it with helm show values.
"The Backup objects vanished." A teammate deletes a CRD to "reinstall it cleanly", then re-creates it. Every object of that kind is gone. Why? Deleting a CRD deletes all its objects. Update a CRD with k apply; never delete it to refresh it.
Keep this
| To | Use |
|---|---|
| Add a chart repo | helm repo add NAME URL, then helm repo update |
| See a chart's settings | helm show values REPO/CHART |
| Install | helm install RELEASE REPO/CHART -n NS --set KEY=VALUE |
| Upgrade, keeping old values | helm upgrade RELEASE REPO/CHART -n NS --reuse-values --set ... |
| History and rollback | helm history RELEASE -n NS, helm rollback RELEASE N -n NS |
| What values a release uses | helm get values RELEASE -n NS (--revision N, --all) |
| Render to a file | helm template RELEASE REPO/CHART --skip-tests > FILE |
| Find releases | helm list -A |
| Remove | helm uninstall RELEASE -n NS |
| Preview a kustomization | k kustomize DIR |
| Apply a kustomization | k apply -k DIR |
| List custom types | k get crd, k api-resources |
| A custom type's fields | k explain KIND.spec |
Where you are now
You've installed, upgraded, rolled back, rendered and removed a Helm release, and seen the two ways Helm quietly loses a setting. You've built a prod environment from a Kustomize base without touching the base, and made your own kind of Kubernetes object, validated by the API server. With RBAC and the upgrade, that covers the Cluster Architecture domain. Lesson 8 moves to Services, DNS and NetworkPolicies, where Calico's enforcement finally matters.
Check yourself
A release was installed with --set replicaCount=4. Someone runs helm upgrade web repo/chart --set image.tag=2.0. How many replicas does the release have now?
helm history shows revisions 1 and 2. You run helm rollback web 1. What does history show next?
You run helm template web podinfo/podinfo --set replicaCont=3 and the rendered file says replicas: 1. Why?
A Kustomize overlay sets namePrefix: prod- on a base whose Service selects app: shop. After k apply -k, does the Service find the Deployment's pods?
You create a CRD for kind Backup and an object of that kind. At the scheduled time, nothing happens. What's missing?
Which command shows a custom type's group, version, kind and whether it's namespaced?
Key terms
- Helm: a package manager for Kubernetes: packaging, templating and release history.
- Chart: a Helm package of templates and default values.
- Values: the settings that fill a chart's templates.
- Release / revision: an installed copy of a chart, and each numbered version of it.
- Rendering: filling a chart's templates to produce plain YAML, the manifest.
- Kustomize: a tool built into kubectl that builds YAML from a base and overlays, without templates.
- Base / overlay: the shared YAML, and the per-environment changes applied on top of it.
- CRD (Custom Resource Definition): adds a new kind of object to the API server.
- Custom resource: an object of a kind a CRD defined.
- Controller / operator: a program that watches objects and acts on them.
- CRI / CNI / CSI: the plugin interfaces for container runtimes, networking and storage.