Kubernetes Pod Scheduling: nodeSelector and Node Affinity
Start with nodeSelector for simple node targeting, then upgrade to node affinity for expressive matching that nodeSelector cannot handle.
Focused, hands-on problems for sharpening your DevOps and server-side skills. Some teach specific concepts while others mirror real-world scenarios. Every challenge includes hints, feedback, and automated solution checks.
Start with nodeSelector for simple node targeting, then upgrade to node affinity for expressive matching that nodeSelector cannot handle.
See how Kubernetes determines BestEffort, Burstable, and Guaranteed classes from resource configuration - and which pods get evicted first under pressure.
See how CPU and memory requests influence where pods land - and what happens when no node can fit them.
Spread pods evenly across nodes and availability zones using maxSkew and zone-aware topology keys.
Co-locate pods that belong together and keep apart pods that should not share a node using affinity and anti-affinity rules.
Create a Deployment with specific scheduling, labels, and port configuration, then expose it externally using a NodePort Service.