⚙️ DOMAIN 3 · WORKLOADS & SCHEDULING
Workloads & Scheduling
Deployments, StatefulSets, Jobs, ConfigMaps, Secrets, resource limits, pod scheduling, HPA — the core of day-to-day Kubernetes work.
Domain Progress0 / 11 labs
GitHub Repository
opscart / production-cka
📁 workloads/ — labs coming soon
Core Workload Controllers
33
Deployments
Rolling updates, rollback, scaling, strategy tuning
⏸ Pending
40 min
▾
Objectives
- Create a Deployment and perform a rolling update to a new image
- Roll back to the previous revision with
kubectl rollout undo - Configure
maxSurgeandmaxUnavailablefor zero-downtime deploys - Scale imperatively and with
kubectl autoscale
Key Commands
kubectl create deployment rx-api --image=nginx:1.25 --replicas=3
kubectl set image deployment/rx-api nginx=nginx:1.26
kubectl rollout status deployment/rx-api
kubectl rollout undo deployment/rx-api
kubectl rollout history deployment/rx-api
⚡ Exam Tip
Deployment updates and rollbacks appear on nearly every exam. Know rollout undo and rollout history without hesitation.
01-deployments/ — lab files coming soon
34
DaemonSets
Node-per-pod deployment, tolerations, update strategy
⏸ Pending
35 min
▾
Objectives
- Create a DaemonSet and verify one pod runs per node
- Add tolerations to schedule on control plane nodes
- Understand DaemonSet vs Deployment use cases
02-daemonsets/ — lab files coming soon
35
StatefulSets
Ordered pods, stable network identity, volumeClaimTemplates
⏸ Pending
50 min
▾
Objectives
- Create a StatefulSet with a headless service and volumeClaimTemplate
- Verify stable pod names (
app-0,app-1) and DNS entries - Scale down and confirm ordered termination (highest ordinal first)
03-statefulsets/ — lab files coming soon
36
Jobs & CronJobs
Batch workloads, completions, parallelism, schedules
⏸ Pending
45 min
▾
Objectives
- Create a Job with 3 completions and 2 parallel workers
- Create a CronJob and verify job creation on schedule
- Understand
activeDeadlineSecondsandbackoffLimit
Key Commands
kubectl create job rx-batch --image=busybox -- sh -c "echo done"
kubectl create cronjob rx-report --image=busybox \
--schedule="0 2 * * *" -- sh -c "generate-report"
04-jobs-cronjobs/ — lab files coming soon
Configuration
37
ConfigMaps
Env vars, volume mounts, hot reload patterns
⏸ Pending
35 min
▾
Objectives
- Create a ConfigMap from literals, files, and a directory
- Inject as environment variables and as a volume mount
- Update a ConfigMap and observe how mounted volumes reflect the change
Key Commands
kubectl create configmap rx-config \
--from-literal=ENV=production \
--from-literal=LOG_LEVEL=info
kubectl create configmap rx-files --from-file=./config/
05-configmaps/ — lab files coming soon
38
Secrets
Opaque, TLS, Docker registry, encryption at rest
⏸ Pending
40 min
▾
Objectives
- Create Opaque, TLS, and dockerconfigjson secrets
- Mount a Secret as a volume and as environment variables
- Understand base64 encoding vs actual encryption
06-secrets/ — lab files coming soon
Scheduling
39
Resource Limits & Requests
CPU/memory requests, limits, LimitRange, ResourceQuota
⏸ Pending
40 min
▾
Objectives
- Set CPU and memory requests/limits and observe QoS class assigned
- Create a LimitRange to enforce namespace defaults
- Understand Guaranteed vs Burstable vs BestEffort QoS
07-resource-limits/ — lab files coming soon
40
Pod Scheduling
nodeSelector, affinity/anti-affinity, topology spread
⏸ Pending
50 min
▾
Objectives
- Schedule a pod to a specific node using
nodeSelector - Use
requiredDuringSchedulingIgnoredDuringExecutionnode affinity - Set pod anti-affinity to spread replicas across nodes
08-pod-scheduling/ — lab files coming soon
41
Taints & Tolerations
NoSchedule, PreferNoSchedule, NoExecute effects
⏸ Pending
45 min
▾
Objectives
- Taint a node and observe pods no longer schedule on it
- Add a toleration to allow a specific pod on the tainted node
- Understand
NoExecuteandtolerationSeconds
Key Commands
kubectl taint node node01 dedicated=rx-prod:NoSchedule
kubectl taint node node01 dedicated=rx-prod:NoSchedule- # remove
09-taints-tolerations/ — lab files coming soon
42
Autoscaling (HPA)
Horizontal Pod Autoscaler, metrics server, scale triggers
⏸ Pending
50 min
▾
Objectives
- Install metrics-server and verify
kubectl top podsworks - Create an HPA targeting 50% CPU utilisation
- Generate load and watch the HPA scale replicas up
Key Commands
kubectl autoscale deployment rx-api \
--cpu-percent=50 --min=2 --max=10
kubectl get hpa -w
10-autoscaling/ — lab files coming soon
43
Pod Disruption Budgets
minAvailable, maxUnavailable, voluntary disruption protection
⏸ Pending
40 min
▾
Objectives
- Create a PDB protecting a Deployment from fewer than 2 pods available
- Attempt to drain a node and observe PDB blocking the drain
- Understand PDB protects against voluntary disruptions only
11-pod-disruption-budgets/ — lab files coming soon