Kubernetes, one picture at a time
Kubernetes from zero to operators, in plain language. Start with why it exists and the three objects everything builds on (Pod, Deployment, Service), then configuration, networking, storage, scheduling, scaling and security. Every chapter has something you can click, crash or switch.
Learning path
Start here
- 01 Why Kubernetes? Docker by hand stops working at scale; Kubernetes keeps the copies you asked for running
- 02 Docker vs Kubernetes Docker builds and runs containers, Kubernetes manages them; you use both
- 03 Pods The wrapper around your container: one IP, storage, a lifecycle
- 04 Deployments, Services and desired state Keep N Pods alive, give them one stable address, and describe the state you want
Pods in depth
- 05 Pods in depth: what a Pod really is Why Pods exist, sidecars, and why unrelated apps get their own Pod
- 06 Pods in depth: networking Every Pod has a temporary IP; containers in a Pod share localhost and ports
- 07 Pods in depth: storage and lifecycle Volumes, Pending to Running, container crash vs Pod gone, and Pod vs Node
- 08 Pods in depth: writing your first Pod pod.yaml line by line, then apply, get, describe, logs and exec
Workloads and Services
- 09 ReplicaSet Self-healing and scaling, labels and selectors, and why it cannot update Pods
- 10 Deployment Rolling updates, broken releases that stall safely, and kubectl rollout undo
- 11 Service Selectors and endpoints, port vs targetPort, DNS names, and the four Service types
- 12 Pod vs ReplicaSet vs Deployment vs Service The differences side by side, with one complete Deployment + Service example
- 13 Health probes How Kubernetes checks your app is alive and ready, and what it does when it is not
- 14 Managed lifecycle SIGTERM, SIGKILL and the grace period, preStop and postStart hooks, and init containers
- 15 Deployment strategies Four ways to ship a new version, and how to pick one
Configuration and resources
- 16 Environment variables Give your app settings without rebuilding the image: env, process.env, and changing values
- 17 A whole app in one file Six microservices in one all.yaml: env vars, Service names, LoadBalancer vs ClusterIP
- 18 ConfigMaps Keep settings out of the image: env vars, envFrom, files, and what happens when they change
- 19 Secrets Base64 is not encryption, Secret types, env vs files, and what really keeps them safe
- 20 Downward API Let a Pod know its own name, namespace, IP, labels and limits
- 21 Immutable config and templates Versioned config you cannot change by accident, and config files built at startup
- 22 Requests, limits and QoS How requests decide placement, why CPU throttles but memory is killed, and QoS classes
- 23 ResourceQuotas and LimitRanges Namespace budgets, per-container defaults and bounds, and why Pods get refused
Networking
- 24 Networking basics IP, ports, localhost vs 0.0.0.0, IP ranges, DNS, routing, NAT, load balancers, and reading network errors
- 25 Kubernetes networking Pod-to-Pod, Pod-to-Service with kube-proxy, cluster DNS, Ingress, NetworkPolicy, and a debugging checklist
- 26 Headless Services clusterIP: None, DNS that returns every Pod, and stable per-Pod names with StatefulSets
- 27 Ingress and Gateway API Ingress controllers, path and host routing, TLS termination, and the Gateway API
- 28 Network Policies Default deny, allow rules by label, namespaces and IP ranges, egress and the DNS trap
- 29 🎮 Packet Run (game) 35 word-free puzzle levels: cables and IPs, Pod plumbing, Services, Ingress routing, zero-trust NetworkPolicies, DNS debugging, up to guru
Storage
- 30 Volumes: emptyDir and hostPath What survives a crash, a Pod delete or a move; emptyDir for scratch, hostPath and its risks
- 31 PersistentVolumes and claims Static provisioning: PV vs PVC, binding, access modes, and replicas with RWO disks
- 32 StorageClasses Disks created on demand, the default class, Retain vs Delete, and growing a volume
- 33 Ephemeral volumes Generic ephemeral and CSI inline volumes, and which kind of storage to use when
Pod patterns
- 34 Init containers and sidecars Run setup before your app, and helpers next to it, inside one Pod
- 35 Adapter and ambassador Sidecars that translate your app’s output or proxy its outgoing calls
More workload types
- 36 Jobs and CronJobs Run a task to completion, in parallel, or on a schedule
- 37 DaemonSets Node agents for logs, metrics and networking, one copy per machine
- 38 StatefulSets Stable names, ordered start, and a disk per replica for databases
- 39 Singletons and disruptions Exactly one active copy with leader election, and PodDisruptionBudgets
Scheduling and scaling
- 40 Scheduling nodeSelector, affinity, taints and tolerations, topology spread, priority and preemption
- 41 Autoscaling Add Pods, resize Pods, or add nodes automatically when load changes
Security
- 42 securityContext and Pod Security Run as non-root, drop capabilities, read-only filesystems, and Pod Security Standards
- 43 RBAC Who may do what: users, ServiceAccounts, Roles and RoleBindings
Under the hood
- 44 Cluster architecture An interactive map of the control plane, worker nodes and API objects, and one kubectl apply traced end to end
- 45 Controllers Watch, compare, act: how every Kubernetes feature works, and writing your own
- 46 Operators Custom resources plus a controller that runs a complex app for you
- 47 Building images in the cluster Kaniko, Buildpacks and Shipwright: build container images without a Docker daemon