Node fleet, mission 6 of 8
All on one
advanced, about 15 minutes, in the Kubernetes Simulator
Opens once you pass One basket.
The briefing
From Tom Okafor, product manager at Larchwood (a fictional company)
Launch is tomorrow. After last week's node reboot, all four web pods ended up on hackademy-worker, and Dana says one more reboot there takes the whole site down.
I need web spread evenly over the two workers, and kept that way whenever pods are replaced. web.yaml is the manifest.
What you'll do
- web: 4 ready replicas
- Two on each worker
- web's template keeps them even with a topology spread constraint
- Bonus star: Keep the spread a hard rule (DoNotSchedule), not a preference
The mission checks the cluster, not your keystrokes: any fix that works, passes.
Concepts
Topology spread constraints
Keep matching pods evenly over domains, such as nodes (
Read the Kubernetes docskubernetes.io/hostname) or zones.maxSkewis the most one domain may exceed the emptiest. By default every node with the key counts as a domain, tainted ones included;nodeTaintsPolicy: Honorleaves out nodes the pod can't tolerate.
More Node fleet missions
- 1. The right hardware
- 2. Reserved seating
- 3. It doesn't fit
- 4. Kernel patch
- 5. One basket
- 6. All on one
- 7. Not on spot
- 8. Checkout first