Explain the Kubernetes architecture in simple terms.
BeginnerConceptContainers & Kubernetes basics
Answer
In one line: A Kubernetes cluster has a control plane (the brain that makes decisions) and worker nodes (the machines that run your containers).
Control plane components:
- kube-apiserver — the front door. Every request (
kubectl, controllers, nodes) goes through it. - etcd — a key-value database storing the cluster's entire state (desired and current). Back it up!
- kube-scheduler — picks a node for each new pod, based on resource requests, affinity, taints and so on.
- kube-controller-manager — runs controllers that keep reality matching the desired state (for example the ReplicaSet controller creates pods when there are too few).
- cloud-controller-manager — talks to the cloud (creates load balancers, attaches volumes).
Worker node components:
- kubelet — the agent on each node; makes sure the containers for its pods are running and reports status.
- Container runtime — actually runs containers (containerd, CRI-O).
- kube-proxy — sets up networking rules so Services route traffic to the right pods (some clusters replace it with eBPF tools like Cilium).
What happens when you deploy (the flow):
kubectl apply -f deployment.yaml→ sent to the API server.- The API server validates it and stores it in etcd.
- The Deployment controller creates a ReplicaSet; the ReplicaSet controller creates Pod objects.
- The scheduler assigns each pod to a node.
- The kubelet on that node tells the container runtime to pull the image and start the container.
- kubelet reports status back; kube-proxy/CNI make the pod reachable through its Service.
In managed Kubernetes (EKS, AKS, GKE), the cloud provider runs the control plane for you; you manage the worker nodes (or use serverless nodes like Fargate or GKE Autopilot).
Tip for interviews: walking through the "kubectl apply" flow step by step is the best way to prove you understand the architecture.
More on Containers & Kubernetes basics
What is the difference between a Docker image and a container?BeginnerWhat makes a good Dockerfile? Give some best practices.BeginnerWhat is Kubernetes, and why do we need it?BeginnerWhat are Pods, Deployments and Services in Kubernetes?BeginnerWhat are liveness, readiness and startup probes?BeginnerWhat are resource requests and limits in Kubernetes?Beginner