⏱️2 min read · 381 words

Kubernetes (K8s) is the standard platform for running containerized applications at scale in 2026. Every major cloud provider offers managed Kubernetes: EKS (AWS), GKE (Google), AKS (Azure). This beginner guide explains core concepts and gets your first app running in a cluster.
📋 Table of Contents
Core Concepts
- Pod: Smallest deployable unit — one or more containers sharing network/storage
- Deployment: Manages multiple pod replicas, handles rolling updates
- Service: Stable network endpoint for a set of pods
- Namespace: Virtual cluster for resource isolation
- ConfigMap/Secret: Configuration and sensitive data injection
Install kubectl and Minikube (Local Testing)
# Install kubectl
curl -LO https://dl.k8s.io/release/$(curl -Ls https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl
chmod +x kubectl && sudo mv kubectl /usr/local/bin/
# Install Minikube (local cluster)
curl -LO https://storage.googleapis.com/minikube/releases/latest/minikube-linux-amd64
sudo install minikube-linux-amd64 /usr/local/bin/minikube
# Start cluster
minikube start --cpus 2 --memory 4096
kubectl cluster-info
Deploy Your First App
# deployment.yaml
apiVersion: apps/v1
kind: Deployment
metadata:
name: myapp
namespace: default
spec:
replicas: 3
selector:
matchLabels:
app: myapp
template:
metadata:
labels:
app: myapp
spec:
containers:
- name: myapp
image: myapp:1.0
ports:
- containerPort: 8000
resources:
requests:
cpu: 100m
memory: 128Mi
limits:
cpu: 500m
memory: 512Mi
# service.yaml
apiVersion: v1
kind: Service
metadata:
name: myapp-service
spec:
selector:
app: myapp
ports:
- port: 80
targetPort: 8000
type: LoadBalancer
kubectl apply -f deployment.yaml
kubectl apply -f service.yaml
# Check status
kubectl get pods
kubectl get services
kubectl describe pod <pod-name>
Essential kubectl Commands
# Get resources
kubectl get pods -n default
kubectl get deployments
kubectl get services
# View logs
kubectl logs <pod-name>
kubectl logs -f <pod-name> # follow
# Exec into pod
kubectl exec -it <pod-name> -- /bin/bash
# Scale deployment
kubectl scale deployment myapp --replicas=5
# Rolling update (zero downtime)
kubectl set image deployment/myapp myapp=myapp:2.0
# Rollback
kubectl rollout undo deployment/myapp
ConfigMaps and Secrets
# configmap.yaml
apiVersion: v1
kind: ConfigMap
metadata:
name: myapp-config
data:
DATABASE_HOST: postgres-service
APP_ENV: production
---
# secret.yaml
apiVersion: v1
kind: Secret
metadata:
name: myapp-secret
type: Opaque
stringData:
DATABASE_PASSWORD: supersecret
Conclusion
Kubernetes is complex but the core concepts are straightforward. Master Pods, Deployments, and Services, then add Ingress for routing and HorizontalPodAutoscaler for auto-scaling. For production, use a managed service (EKS/GKE/AKS) rather than self-hosting the control plane.
📚 You might also like
🔗 Share this article




✍️ Leave a Comment