Skip to content

savitojs/k8s-learn-by-doing

Repository files navigation

Minikube Logo

K8s Learn by Doing

52 hands-on Kubernetes labs. From your first Deployment to Istio, Knative, Traefik, and production architectures.

Kubernetes Minikube Helm ArgoCD Prometheus Tekton

Lint GitHub Stars License Issues Last Commit


Quick Start

# Check prerequisites
task prereqs

# Start cluster
task cluster:start

# Deploy any demo by number
task demo -- simple-app

# Check status
task status -- simple-app

# Clean up
task clean -- simple-app

Or without Taskfile:

# Start cluster
minikube start --cpus=4 --memory=8192 --disk-size=40g
minikube addons enable ingress && minikube addons enable metrics-server

# Deploy a demo
kubectl apply -f demos/simple-app/manifests/namespace.yaml
kubectl apply -f demos/simple-app/manifests/

# Check status
kubectl get pods -n simple-app

# Clean up
kubectl delete namespace simple-app

See docs/getting-started.md for detailed setup and the cheat sheet for common kubectl commands.


Demos

Packaging & Deployment

# Demo What You Learn Deep Dive Level Time
01 Simple App Deployments, Services, resource limits Beginner ~5 min
02 Helm Chart structure, templating, rollbacks deep-dive Beginner ~10 min
03 Kustomize Base + overlay pattern, multi-env configs deep-dive Intermediate ~10 min
04 ArgoCD GitOps, auto-sync, self-heal, App-of-Apps deep-dive Intermediate ~20 min
30 Tekton Basics Tasks, Pipelines, params, workspaces, results deep-dive Intermediate ~15 min
31 Tekton CI/CD Test, build, deploy pipeline with triggers deep-dive Advanced ~20 min

Infrastructure & Tooling

# Demo What You Learn Deep Dive Level Time
05 Cert-Manager TLS automation, trust chains, auto-provisioning deep-dive Intermediate ~15 min
06 Redis Cache-aside pattern, TTL, LRU, live dashboard deep-dive Intermediate ~15 min
07 YAKD Lightweight read-only cluster dashboard Beginner ~5 min
08 Headlamp Full-featured K8s UI with RBAC and exec Beginner ~10 min

Workload Types

# Demo What You Learn Deep Dive Level Time
09 CloudNativePG Operator-managed PostgreSQL, HA, failover deep-dive Intermediate ~15 min
10 StatefulSet Stable identity, per-pod PVCs, init containers deep-dive Intermediate ~15 min
11 Jobs & CronJobs Batch processing, parallel jobs, schedules deep-dive Beginner ~10 min
12 DaemonSet One pod per node, tolerations, host access deep-dive Beginner ~10 min
26 Multi-Container Sidecar, adapter, ambassador patterns deep-dive Intermediate ~10 min

Networking & Services

# Demo What You Learn Deep Dive Level Time
16 Service Types ClusterIP, NodePort, LoadBalancer, Headless deep-dive Intermediate ~15 min
19 Network Policies Zero-trust networking, deny-all, allow rules deep-dive Intermediate ~15 min

Configuration & Reliability

# Demo What You Learn Deep Dive Level Time
17 ConfigMaps & Secrets Env vars, volume mounts, immutable configs deep-dive Beginner ~10 min
18 Probes & Lifecycle Health checks, graceful shutdown, preStop hooks deep-dive Intermediate ~15 min
21 Pod Disruption Budgets Availability during maintenance deep-dive Intermediate ~10 min
23 Deployment Strategies Rolling, blue/green, canary patterns deep-dive Intermediate ~15 min

Scaling & Resource Management

# Demo What You Learn Deep Dive Level Time
13 HPA Horizontal Pod Autoscaler, CPU-based scaling deep-dive Intermediate ~15 min
20 Resource Quotas ResourceQuota, LimitRange, namespace governance deep-dive Intermediate ~10 min

Security & Access Control

# Demo What You Learn Deep Dive Level Time
14 RBAC ServiceAccounts, Roles, RoleBindings deep-dive Intermediate ~10 min
24 Pod Security SecurityContext, Pod Security Standards deep-dive Intermediate ~10 min
28 Vault Secret management, policies, K8s auth deep-dive Intermediate ~20 min
29 External Secrets ESO syncs Vault into K8s Secrets deep-dive Intermediate ~15 min

Observability & Debugging

# Demo What You Learn Deep Dive Level Time
22 Prometheus & Grafana Monitoring stack, PromQL, dashboards, alerts deep-dive Intermediate ~20 min
25 kubectl Debug Ephemeral containers, CrashLoop debugging deep-dive Intermediate ~10 min

Extensibility

# Demo What You Learn Deep Dive Level Time
15 CRDs & Operators Custom resources, reconciliation, operator pattern deep-dive Advanced ~20 min

Storage

# Demo What You Learn Deep Dive Level Time
27 PersistentVolumes PVs, PVCs, StorageClasses, dynamic provisioning deep-dive Intermediate ~10 min

Real-World Architectures

Note: These demos run multi-service stacks and need more resources. Clean up other demos first (task clean:all) and allocate at least 6 CPUs / 12GB RAM to minikube.

# Demo What You Build Deep Dive Level Time
32 Microservices Platform Frontend + API + Worker + Redis + PostgreSQL deep-dive Intermediate ~20 min
33 API Gateway (Kong) Rate limiting, API key auth, load balancing deep-dive Intermediate ~15 min
34 Event-Driven (Kafka) Async messaging with producers and consumers deep-dive Advanced ~20 min
35 EFK Logging Fluent Bit + Elasticsearch + Kibana deep-dive Intermediate ~20 min
36 ML Model Serving Prediction API with auto-scaling under load deep-dive Intermediate ~15 min
37 GitOps Full Loop Tekton CI + ArgoCD CD, end-to-end deep-dive Advanced ~20 min
38 Multi-Tenant Platform 3 teams, RBAC + Quotas + NetworkPolicies deep-dive Intermediate ~15 min
39 Chaos Engineering Break things, watch K8s self-heal deep-dive Intermediate ~15 min
40 Progressive Delivery Argo Rollouts canary with auto-rollback deep-dive Advanced ~20 min

Advanced Tools

# Demo What You Learn Deep Dive Level Time
41 Istio Service Mesh mTLS, traffic splitting, observability deep-dive Advanced ~20 min
42 Kyverno Policy enforcement, validation, mutation deep-dive Intermediate ~15 min
43 Velero Backup, restore, disaster recovery deep-dive Intermediate ~20 min
44 Sealed Secrets GitOps-safe encrypted secrets deep-dive Intermediate ~15 min
45 VPA Auto right-sizing resource requests deep-dive Intermediate ~15 min
46 Advanced Ingress & Routing Gateway API, Traefik, HTTPRoute, middleware deep-dive Advanced ~30 min
47 Reloader Auto-restart pods on ConfigMap/Secret changes deep-dive Beginner ~10 min
48 Knative Serving Scale-to-zero, revisions, traffic splitting deep-dive Intermediate ~20 min
49 Trivy Operator Container vulnerability scanning, CVE detection deep-dive Intermediate ~15 min
50 Falco Runtime threat detection, eBPF syscall monitoring deep-dive Advanced ~20 min
51 OpenTelemetry & Tracing Distributed tracing, Jaeger, spans, trace context deep-dive Intermediate ~20 min

Architecture

graph LR
    subgraph "Your Machine"
        A[kubectl / Taskfile] --> B[Minikube]
    end
    subgraph "Minikube Cluster"
        B --> C[52 Labs]
        C --> D[Pods / Services / CRDs]
    end
Loading

Taskfile Commands

Command Description
task prereqs Check all prerequisites are installed
task cluster:start Start minikube with recommended settings
task cluster:stop Stop the cluster
task list List all available demos
task demo -- redis Deploy demo 06 (Redis)
task status -- redis Check pod status for demo 06
task clean -- redis Clean up demo 06
task clean:all Clean up ALL demo namespaces
task validate Run all linting and validation

Contributing

See CONTRIBUTING.md for the demo template, style guide, and submission checklist.

License

MIT License. See LICENSE for details.


If you find this useful, please give it a star to help others find it.

About

50+ hands-on Kubernetes labs with minikube. From your first Deployment to Istio, Knative, Traefik, and production architectures. Each lab: manifests, quickstart, deep-dive docs.

Topics

Resources

License

Contributing

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors