k8s 污点之NoSchedule案例
1.打污点
kubectl taint node worker232 school=baimei:NoSchedule
kubectl describe nodes | grep -i taints
2.资源清单
cat 02-taint.yaml
apiVersion: apps/v1
kind: Deployment
metadata:
name: deploy-taint-class
spec:
replicas: 10
selector:
matchExpressions:
- key: apps
values:
- "v1"
- "v2"
operator: NotIn
template:
metadata:
labels:
class: linux86
spec:
containers:
- name: v1
image: harbor.baimei.com/baimei-apps/apps:v1