Kubernetes Architecture and Cluster Components
A Kubernetes cluster consists of control plane nodes and worker nodes. Control plane components manage and maintain cluster state, while worker nodes run application containers.
Pods and Workloads
A Pod is the smallest deployable unit in Kubernetes, encapsulating one or more containers that share:- A network namespace (IP address and ports)
- Shared storage volumes
- Container execution configuration
To achieve high availability and self-healing, wrap pods in higher-level controllers such as ReplicaSets and Deployments.
ReplicaSets and Deployments
- ReplicaSet: Ensures a specified number of pod replicas are running at any time.
- Deployment: Declaratively manages ReplicaSets to facilitate rolling updates and rollbacks.
Service Discovery and Networking
Kubernetes Services provide stable endpoints to access pods. Common types include:Provisioning a
LoadBalancer service may incur additional cloud provider costs. Review your cloud network pricing before use.Ingress
Ingress resources enable advanced HTTP(S) routing:- Path-based routing: Route requests by URL path (e.g.,
/app1,/app2). - Host-based routing: Direct traffic based on hostname (e.g.,
app.example.com). - TLS termination: Consolidate HTTPS certificates at the edge.