Containers revolutionized software delivery β fast, portable, and reliable.
But managing hundreds of containers across servers? Thatβs where Kubernetes (K8s) comes in.
Letβs explore the complete architecture of Kubernetes, why itβs used, and how it powers modern cloud infrastructure. π©οΈ
π§ What is Kubernetes?
Kubernetes (K8s) is an open-source container orchestration platform originally developed by Google and now maintained by the Cloud Native Computing Foundation (CNCF).
It automates:
- π§© Deployment of containers
- βοΈ Scaling and load balancing
- π οΈ Self-healing and rolling updates
- π Configuration and secrets management
In short:
Kubernetes ensures your containerized applications run exactly as intended β automatically and reliably.
π§© Kubernetes Core Architecture Overview
Kubernetes is built on two major layers:
- Control Plane (Master) β Brains of the cluster
- Worker Nodes β Muscles that actually run workloads
Letβs break them down π
π§ 1οΈβ£ Control Plane (Master Components)
These components manage the overall cluster state.
| Component | Description |
|---|---|
API Server (kube-apiserver) |
The front door of the cluster. Handles REST requests, validates configuration, and updates the cluster state in etcd. |
| etcd | A distributed key-value store that holds all cluster data (desired & current state). Acts as the source of truth. |
Scheduler (kube-scheduler) |
Decides which node runs a new Pod based on available resources and policies. |
Controller Manager (kube-controller-manager) |
Ensures the cluster matches the desired configuration (e.g., if a Pod fails, it starts a new one). |
| Cloud Controller Manager | Connects Kubernetes with underlying cloud services like load balancers and storage. |
πͺ 2οΈβ£ Worker Nodes (Data Plane)
Worker nodes actually run your containers.
Each node runs the following key components:
| Component | Description |
|---|---|
| Kubelet | Node agent that ensures containers are running as per the API serverβs instructions. |
| Kube Proxy | Manages networking, traffic routing, and load balancing between services. |
| Container Runtime | Runs containers (e.g., Docker, containerd, CRI-O). Responsible for pulling images and starting containers. |
π§± 3οΈβ£ Kubernetes Objects
Kubernetes uses declarative configuration files (YAML) to manage workloads.
| Object | Description |
|---|---|
| Pod π§« | The smallest deployable unit; runs one or more containers together. |
| ReplicaSet π | Ensures the desired number of identical Pods are always running. |
| Deployment π | Manages rollout, rollback, and scaling of applications. |
| Service π | Provides stable networking and load balancing between Pods. |
| ConfigMap / Secret π | Externalize configuration and sensitive data. |
| Ingress π | Routes external HTTP(S) traffic to internal services. |
| Namespace π¦ | Organizes cluster resources logically for isolation. |
ποΈ 6οΈβ£ Kubernetes Architecture Diagram (Text View)
ββββββββββββββββββββββββββββ
β Load Balancer (LB) β
ββββββββββββββββ¬ββββββββββββ
β
ββββββββββββββββββββββ΄βββββββββββββββββββββββ
β Control Plane Nodes β
β (API Server, etcd, Scheduler, Controllers)β
ββββββββββββββββββββββ¬βββββββββββββββββββββββ
β
ββββββββββββββββββββββ΄βββββββββββββββββββββββ
β Worker Nodes β
β (Kubelet, Kube Proxy, Containers/Pods) β
ββββββββββββββββββββββ¬βββββββββββββββββββββββ
β
βββββββββββββββ΄ββββββββββββββ
β Services & Ingress β
βββββββββββββββ¬ββββββββββββββ
β
User Traffic π
Top comments (0)