Skip to content

Latest commit

 

History

History
58 lines (38 loc) · 1 KB

scheduling.md

File metadata and controls

58 lines (38 loc) · 1 KB
layout title permalink nav_order
page
Scheduling
/scheduling
4

Scheduling pods - affinity pattern

Check node labels

kubectl get nodes --show-labels

Create new deployment without affinity

kubectl apply -f exercice-files/lab4-1.yaml

Check pods location

kubectl get pods -ocustom-columns=NAME:.metadata.name,NODE:.spec.nodeName

Recreate deployment with affinity

kubectl replace -f exercice-files/lab4-2.yaml

Check pods location

kubectl get pods -ocustom-columns=NAME:.metadata.name,NODE:.spec.nodeName

Clean up

kubectl delete -f exercice-files/lab4-2.yaml

To go further check the official documentation