Kubernetes
The industry-standard container orchestrator - from your first deployment to production-ready clusters
Kubernetes
Kubernetes (K8s) automates the deployment, scaling, and management of containerized applications. You describe the desired state of your workloads in YAML, and Kubernetes continuously reconciles reality with that description.
Why Kubernetes
| Without K8s | With K8s |
|---|---|
| Manual restarts when a container dies | Self-healing — controllers restart failed pods |
| Manual scaling: SSH and start more containers | Declarative scale; HPA can do it automatically |
| Per-host service discovery hacks | Built-in DNS and load balancing |
| Custom deploy scripts | Rolling updates and rollbacks are a primitive |
| Vendor-specific automation | Same API across every cloud and on-prem |
Cluster Architecture
┌────────────────── Control Plane ──────────────────┐
│ │
│ ┌──────────┐ ┌──────────┐ ┌──────────────────┐ │
│ │ kube-api │ │ etcd │ │ controller-mgr │ │
│ │ -server │ │ (kv DB) │ │ + scheduler │ │
│ └─────┬────┘ └──────────┘ └──────────────────┘ │
│ │ kubectl / clients │
└────────┼───────────────────────────────────────────┘
│
┌─────┴──────────────────────────────┐
│ │
▼ ▼
┌─────────────────┐ ┌─────────────────┐
│ Worker Node 1 │ ......... │ Worker Node N │
│ ┌───────────┐ │ │ ┌───────────┐ │
│ │ kubelet │ │ │ │ kubelet │ │
│ │ kube-proxy│ │ │ │ kube-proxy│ │
│ └───────────┘ │ │ └───────────┘ │
│ ┌──────┐┌──────┐│ │ ┌──────┐┌──────┐│
│ │ Pod ││ Pod ││ │ │ Pod ││ Pod ││
│ └──────┘└──────┘│ │ └──────┘└──────┘│
└─────────────────┘ └─────────────────┘You write YAML → kubectl apply → the API server stores it in etcd → controllers notice the new desired state → the scheduler picks a node → kubelet on that node pulls the image and starts the pod.
Learning Path
Read in this order if you're new — each page builds on the previous one.
1. Getting Started
Install kubectl, get a cluster, deploy your first app
2. Workloads
Pods, Deployments, StatefulSets, DaemonSets, Jobs, CronJobs
3. Networking
Services, Ingress, DNS, NetworkPolicies
4. Config & Storage
ConfigMaps, Secrets, Volumes, PersistentVolumes
5. Scaling & Rollouts
HPA, rolling updates, debugging, kubectl in anger
6. Best Practices
RBAC, security, GitOps, production patterns
When NOT to Use Kubernetes
K8s is not free in operational complexity. Reach for it when:
- You run many services, not just one.
- You need rolling updates, autoscaling, and self-healing as table-stakes.
- You're across multiple clouds or want to be.
Skip it (or use a managed PaaS like Cloud Run, App Runner, Fly.io) when:
- You're a small team running one or two services.
- Latency to "first deploy" matters more than orchestration features.
- You don't have a person who'll own the cluster.
Kubernetes is the runtime. You still need Docker (or another container runtime) to build images, and a CI/CD system to ship them. K8s orchestrates what those images do once they exist.