From aadce39ddeb9d552cada90a5baad56a3b3e8b20b Mon Sep 17 00:00:00 2001 From: qiuming520 Date: Fri, 13 Oct 2023 16:16:26 +0800 Subject: [PATCH] fix kosmos-scheduler miss lease permission Signed-off-by: qiuming520 --- deploy/scheduler/deployment.yaml | 4 +++- deploy/scheduler/rbac.yaml | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/deploy/scheduler/deployment.yaml b/deploy/scheduler/deployment.yaml index c92742e3b..8acc679c2 100644 --- a/deploy/scheduler/deployment.yaml +++ b/deploy/scheduler/deployment.yaml @@ -25,8 +25,10 @@ spec: - name: kosmos-scheduler image: ghcr.io/kosmos-io/scheduler:0.0.2 command: - - /scheduler + - scheduler - --leader-elect=true + - --leader-elect-resource-name=kosmos-scheduler + - --leader-elect-resource-namespace=kosmos-system - --config=/etc/kubernetes/kube-scheduler/scheduler-config.yaml resources: requests: diff --git a/deploy/scheduler/rbac.yaml b/deploy/scheduler/rbac.yaml index 5f9aa3ddb..fb460fd67 100644 --- a/deploy/scheduler/rbac.yaml +++ b/deploy/scheduler/rbac.yaml @@ -48,7 +48,7 @@ rules: resources: - leases resourceNames: - - kube-scheduler + - kosmos-scheduler - verbs: - create apiGroups: