Last active
September 7, 2022 08:19
-
-
Save ykfq/4ffb4e31d6004d09f1abbb0d7f30f48d to your computer and use it in GitHub Desktop.
Get the taints on all nodes in one command.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
root@master001:~# kubectl describe node | egrep "Taints" | |
Taints: gpu=yes:NoSchedule | |
Taints: <none> | |
Taints: <none> | |
Taints: <none> | |
Taints: node-role.kubernetes.io/master:NoSchedule | |
Taints: node-role.kubernetes.io/master:NoSchedule | |
Taints: node-role.kubernetes.io/master:NoSchedule | |
Taints: <none> | |
Taints: <none> | |
#---------- or ----------- | |
kubectl describe node | egrep "Name:|Taints" |
kubectl get nodes -o custom-columns=NAME:metadata.name,TAINT:spec.taints[].effect,KEY:spec.taints[].key,VALUE:spec.taints[*].value
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
it shows only the first taint