KASHII UPDATEZ Everyday Student Requirements & Python Coding Tutorials by Python Kashi
KashiiUpdatez
← Back to Tech Blog

Kubernetes for Developers: Pods, Services, Deployments and Helm Charts Explained

Kubernetes does not have to be intimidating. Learn the core objects β€” Pods, Deployments, Services, Ingress, ConfigMaps, Secrets β€” with real YAML manifests for a Django + Next.js app, then package it all with a Helm chart.

Kashinath Chavan
Kashinath Chavan
Developer Tooling & Compilers ⏱️ 4 min read Aug 18, 2026
Follow β†—
Kubernetes for Developers: Pods, Services, Deployments and Helm Charts Explained

Kubernetes in Plain English

Kubernetes (K8s) takes your Docker containers and decides where to run them, restarts them if they crash, scales them up when traffic increases, and routes traffic to the right containers.

ObjectWhat It DoesAnalogy
PodRuns one or more containers togetherA single process group
DeploymentManages replicas of Pods, handles rolling updatesA supervisor managing workers
ServiceStable network endpoint for a set of PodsA load balancer / DNS name
IngressHTTP/HTTPS routing from external traffic to ServicesAn Nginx reverse proxy
ConfigMapNon-secret configuration as key-value pairsEnvironment variables file
SecretSensitive data (base64-encoded)Encrypted .env file

1. Deploy Django to Kubernetes

ConfigMap β€” Application Settings

apiVersion: v1
kind: ConfigMap
metadata:
  name: django-config
  namespace: production
data:
  DJANGO_SETTINGS_MODULE: "reqpulse.settings"
  ALLOWED_HOSTS: "kashiiupdatez.online"
  DEBUG: "False"
  DATABASE_HOST: "postgres-service"
  REDIS_URL: "redis://redis-service:6379/0"

Deployment β€” Django App with Rolling Updates

apiVersion: apps/v1
kind: Deployment
metadata:
  name: django-web
  namespace: production
spec:
  replicas: 3
  selector:
    matchLabels:
      app: django-web
  strategy:
    type: RollingUpdate
    rollingUpdate:
      maxSurge: 1
      maxUnavailable: 0
  template:
    metadata:
      labels:
        app: django-web
    spec:
      containers:
        - name: django
          image: ghcr.io/kashichavan/kashii-updatez:latest
          ports:
            - containerPort: 8000
          envFrom:
            - configMapRef:
                name: django-config
            - secretRef:
                name: django-secrets
          resources:
            requests:
              memory: "256Mi"
              cpu: "250m"
            limits:
              memory: "512Mi"
              cpu: "500m"
          readinessProbe:
            httpGet:
              path: /health/
              port: 8000
            initialDelaySeconds: 15
          livenessProbe:
            httpGet:
              path: /health/
              port: 8000
            initialDelaySeconds: 30
      initContainers:
        - name: migrate
          image: ghcr.io/kashichavan/kashii-updatez:latest
          command: ["python", "manage.py", "migrate", "--noinput"]
          envFrom:
            - configMapRef:
                name: django-config
            - secretRef:
                name: django-secrets

Ingress β€” External HTTP Routing with TLS

apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
  name: kashii-ingress
  namespace: production
  annotations:
    cert-manager.io/cluster-issuer: "letsencrypt-prod"
spec:
  ingressClassName: nginx
  tls:
    - hosts:
        - kashiiupdatez.online
      secretName: kashii-tls-cert
  rules:
    - host: kashiiupdatez.online
      http:
        paths:
          - path: /
            pathType: Prefix
            backend:
              service:
                name: django-service
                port:
                  number: 80

2. Horizontal Pod Autoscaler

apiVersion: autoscaling/v2
kind: HorizontalPodAutoscaler
metadata:
  name: django-hpa
  namespace: production
spec:
  scaleTargetRef:
    apiVersion: apps/v1
    kind: Deployment
    name: django-web
  minReplicas: 2
  maxReplicas: 10
  metrics:
    - type: Resource
      resource:
        name: cpu
        target:
          type: Utilization
          averageUtilization: 70

3. Essential kubectl Commands

kubectl apply -f k8s/                      # Apply all YAML in directory
kubectl set image deployment/django-web django=ghcr.io/kashichavan/kashii:v2.1.0

kubectl get pods -n production             # List pods
kubectl describe pod django-web-abc123     # Detailed pod info
kubectl logs django-web-abc123 --follow    # Stream logs
kubectl exec -it django-web-abc123 -- bash # Shell into pod

kubectl rollout history deployment/django-web
kubectl rollout undo deployment/django-web
kubectl scale deployment django-web --replicas=5

4. Packaging with Helm

helm create kashii-chart   # Generates scaffold
# values.yaml
image:
  repository: ghcr.io/kashichavan/kashii-updatez
  tag: "latest"
replicaCount: 3
ingress:
  enabled: true
  host: kashiiupdatez.online
  tls: true
resources:
  requests:
    memory: "256Mi"
    cpu: "250m"
helm upgrade --install kashii ./kashii-chart   --namespace production   --set image.tag=$(git rev-parse --short HEAD)

helm rollback kashii 2   # Roll back to revision 2
Topics: #Deployment #Devops #Docker #Helm #K8S #Kubernetes
πŸ‘οΈ 3123 views

More from Developer Tooling & Compilers

Chat Chat with Kashii