Kubernetes, often abbreviated as K8s, is an open-source container orchestration platform designed to automate the deployment, scaling, and management of containerized applications. It was originally developed by Google and is now maintained by the Cloud Native Computing Foundation (CNCF).
Kubernetes manages containerized applications automatically, ensuring smooth operations.
✅ Automated deployment & rollback
✅ Self-healing - Restarts failed containers
✅ Horizontal scaling - Scales applications dynamically
K8s provides built-in service discovery and load balancing.
🔗 ClusterIP - Internal service access
🌍 NodePort - Exposes services externally
🖧 LoadBalancer - Uses cloud provider’s LB
With Kubernetes, you define your infrastructure as YAML manifests, making it easy to maintain and replicate.
📜 Declarative Configuration:
apiVersion: apps/v1
kind: Deployment
metadata:
name: my-app
spec:
replicas: 3
selector:
matchLabels:
app: my-app
template:
metadata:
labels:
app: my-app
spec:
containers:
- name: my-app
image: my-app:v1
ports:
- containerPort: 80
Kubernetes works seamlessly across on-premise, public cloud, and hybrid cloud environments.
✅ Cloud-Native - Works with AWS, GCP, Azure
✅ Edge Computing - Deploy workloads at the edge
✅ Hybrid Deployments - Combine cloud and on-premises
The Control Plane manages the cluster and ensures the desired state is maintained.
🔹 API Server (kube-apiserver) - Frontend for Kubernetes API
🔹 Controller Manager (kube-controller-manager) - Maintains cluster state
🔹 Scheduler (kube-scheduler) - Assigns workloads to nodes
🔹 etcd - Stores cluster configuration
Worker nodes run application containers and report back to the master node.
🔹 Kubelet - Agent running on nodes
🔹 Kube Proxy - Manages networking
🔹 Container Runtime - Runs containers (Docker, containerd, CRI-O)
The smallest deployable unit in Kubernetes that can contain one or more containers.
Ensures application replicas run smoothly and handle updates.
Exposes applications to internal and external networks.
Manages configuration data and sensitive information.
Manages external HTTP and HTTPS traffic to services.
Restrict user and application permissions.
Control traffic between pods and external resources.
Isolate workloads using Kubernetes Namespaces.
🔹 Prometheus - Metrics collection and alerting
🔹 Grafana - Data visualization
🔹 Loki - Log aggregation
🔹 Jaeger - Distributed tracing
Amazon EKS (Elastic Kubernetes Service) is a managed Kubernetes service by AWS.
✅ Fully managed control plane
✅ Seamless integration with AWS services
✅ Supports Fargate for serverless Kubernetes