Skip to content

Kubernetes Introduction

Kubernetes (K8s) is an open-source container orchestration platform. It automates deploying, scaling, and managing containerised applications across a cluster of machines.

Docker solves packaging. Kubernetes solves operations at scale.

Without orchestration you face:

  • Manual restarts when containers crash
  • No built-in load balancing across replicas
  • No rolling deployments without downtime
  • No automatic scaling under load

Kubernetes handles all of this declaratively — you describe desired state, and the control plane makes it reality.

Control Plane (manages the cluster)
├── API Server — single entry point for all operations
├── etcd — distributed key-value store for cluster state
├── Scheduler — assigns pods to nodes based on resources
└── Controller Manager — reconciliation loops (deployments, replicas, etc.)
Worker Nodes (run the workloads)
├── kubelet — agent that runs pods on the node
├── kube-proxy — network rules and service routing
└── Container Runtime — containerd or Docker
ConceptWhat it is
PodSmallest deployable unit — one or more containers
NodeA machine (VM or physical) in the cluster
ClusterOne control plane + multiple worker nodes
NamespaceLogical partition within a cluster
DeploymentManages replicas and rolling updates of pods
ServiceStable network endpoint in front of pods
ConfigMap / SecretExternal configuration and sensitive values
IngressHTTP routing from outside the cluster to services
ConcernDocker aloneKubernetes
Container restart on crashManual or restart policyAutomatic
Load balancingManual with nginx/HAProxyBuilt-in via Services
Rolling updatesManual scriptingkubectl rollout
Auto-scalingNot built-inHorizontalPodAutoscaler
Multi-host networkingComplex setupBuilt-in overlay network

Use plain Docker for local development and single-host deployments. Use Kubernetes when you need multi-node workloads, auto-scaling, or zero-downtime deployments.

Good fit:

  • Microservices with independent scaling requirements
  • High-availability production workloads
  • Teams that ship frequently and need zero-downtime deploys

Might be overkill:

  • Small single-service apps
  • Prototypes or internal tools
  • Teams without operational capacity to maintain a cluster (consider managed alternatives like Cloud Run or Azure Container Apps)

All major clouds offer managed control planes so you only manage worker nodes:

  • GKE — Google Kubernetes Engine
  • AKS — Azure Kubernetes Service
  • EKS — Amazon Elastic Kubernetes Service