Kubernetes lessons
37 lessons on how a cluster works, from packets on the wire up to the app
37 lessons
Network
9 lessons
- A request finds your Pod
Load balancer to container
- Pod to Pod, same node
veth pairs and the bridge
- Pod to Pod, across nodes
The VXLAN overlay
- Pod calls a Service
ClusterIP and kube-proxy
- DNS in the cluster
CoreDNS and ndots:5
- Ingress and Gateway API
Host and path routing
- NetworkPolicy
A packet gets dropped
- Cilium and eBPF
Identity instead of IPs
- Service mesh with Istio
A proxy beside every app
Node
6 lessons
- Starting a container
Namespaces and cgroups
- Pulling an image
Manifests, layers, cache
- Probes and restarts
CrashLoopBackOff, explained
- OOMKilled
Memory limits in practice
- Mounting a volume
CSI attach and mount
- A Pod asks for a GPU
Device plugins and extended resources
Control plane
10 lessons
- Deploy an app
kubectl apply → Pod Running
- List and watch
How components stay in sync
- The scheduler
Filter, score, bind
- Reconcile loops
Desired vs. actual state
- A node goes dark
Heartbeats and eviction
- A node joins the cluster
Autoscaler, bootstrap, Ready
- Draining a node
Cordon, evict, PodDisruptionBudget
- Upgrading the cluster
Control plane first, then each node
- Backing up and restoring etcd
Snapshot, restore, reconcile
- Kyverno policies
Who checks your YAML
App
8 lessons
- Rolling update
New version, zero downtime
- Graceful shutdown
SIGTERM and the endpoint race
- Autoscaling
HPA and metrics-server
- Scale to zero with KEDA
Queue length and external metrics
- Starting a model server
Big images, slow loads, startup probes
- ConfigMaps and Secrets
Getting config into a Pod
- StatefulSet with storage
Stable names, ordered starts
- Jobs and CronJobs
Run to completion
Security
4 lessons
- RBAC and ServiceAccounts
Who can do what
- A Pod gets AWS credentials
Projected tokens and OIDC
- Quotas and defaults for a tenant
LimitRange, ResourceQuota, Pod Security
- Runtime alerts with Falco
Watching the kernel