chroe: add k8s node-role.kubernetes.io/control-plane taint

Signed-off-by: xin.li <xin.li@daocloud.io>
This commit is contained in:
xin.li 2023-01-02 21:04:43 +08:00
parent 00aae4c10c
commit 10ca605cdd
2 changed files with 5 additions and 2 deletions

View File

@ -612,11 +612,11 @@ func TestPrintNodeRole(t *testing.T) {
node: api.Node{ node: api.Node{
ObjectMeta: metav1.ObjectMeta{ ObjectMeta: metav1.ObjectMeta{
Name: "foo10", Name: "foo10",
Labels: map[string]string{"node-role.kubernetes.io/master": "", "node-role.kubernetes.io/proxy": "", "kubernetes.io/role": "node"}, Labels: map[string]string{"node-role.kubernetes.io/master": "", "node-role.kubernetes.io/control-plane": "", "node-role.kubernetes.io/proxy": "", "kubernetes.io/role": "node"},
}, },
}, },
// Columns: Name, Status, Roles, Age, KubeletVersion // Columns: Name, Status, Roles, Age, KubeletVersion
expected: []metav1.TableRow{{Cells: []interface{}{"foo10", "Unknown", "master,node,proxy", "<unknown>", ""}}}, expected: []metav1.TableRow{{Cells: []interface{}{"foo10", "Unknown", "control-plane,master,node,proxy", "<unknown>", ""}}},
}, },
{ {
node: api.Node{ node: api.Node{

View File

@ -25,6 +25,9 @@ spec:
- key: node-role.kubernetes.io/master - key: node-role.kubernetes.io/master
operator: Exists operator: Exists
effect: NoSchedule effect: NoSchedule
- key: node-role.kubernetes.io/control-plane
operator: Exists
effect: NoSchedule
serviceAccountName: sriov-device-plugin serviceAccountName: sriov-device-plugin
containers: containers:
- name: kube-sriovdp - name: kube-sriovdp