

kubectl get nodes --show-labels

kubectl label nodes 172.31.2.7 uavcloud.env=szgz --overwrite
kubectl label nodes 172.31.2.8 uavcloud.env=szgz --overwrite
kubectl label nodes 172.31.2.9 uavcloud.env=szgz --overwrite
kubectl label nodes 192.168.233.100 uavcloud.affinity=common --overwrite


# 删除label
kubectl label nodes 192.168.40.193 uavcloud.env-

# 获取特定label的节点
kubectl get nodes -l uavcloud.affinity=common

