From 9b2cffea093a3bfd8fe95044d557bc605c2c74ed Mon Sep 17 00:00:00 2001 From: David Collom Date: Sat, 23 Apr 2022 08:25:34 +0100 Subject: [PATCH] feat(argo-events): Adding additional RBAC for leader election (#1242) * Issue 1565: Adding additional RBAC for leader election Signed-off-by: David Collom * Adding Additional RBAC for Events Signed-off-by: David Collom * Use consistent indent style Signed-off-by: Marco Kilchhofer * Bump minor chart version and add changelog Signed-off-by: Marco Kilchhofer Co-authored-by: Marco Kilchhofer --- charts/argo-events/Chart.yaml | 4 ++-- .../templates/argo-events-cluster-roles.yaml | 19 +++++++++++++++++++ .../templates/argo-events-roles.yaml | 19 +++++++++++++++++++ 3 files changed, 40 insertions(+), 2 deletions(-) diff --git a/charts/argo-events/Chart.yaml b/charts/argo-events/Chart.yaml index f5783785..977749af 100644 --- a/charts/argo-events/Chart.yaml +++ b/charts/argo-events/Chart.yaml @@ -1,7 +1,7 @@ apiVersion: v2 description: A Helm chart to install Argo-Events in k8s Cluster name: argo-events -version: 1.12.0 +version: 1.13.0 keywords: - argo-events - sensor-controller @@ -17,4 +17,4 @@ icon: https://argoproj.github.io/argo-events/assets/logo.png home: https://github.com/argoproj/argo-helm annotations: artifacthub.io/changes: | - - "[Added]: Add aggregate-roles (sync with upstream manifests)" + - "[Added]: Additional RBAC for leader election" diff --git a/charts/argo-events/templates/argo-events-cluster-roles.yaml b/charts/argo-events/templates/argo-events-cluster-roles.yaml index cef1ad2e..efdd6101 100644 --- a/charts/argo-events/templates/argo-events-cluster-roles.yaml +++ b/charts/argo-events/templates/argo-events-cluster-roles.yaml @@ -28,6 +28,25 @@ rules: {{- with .Values.additionalServiceAccountRules }} {{- toYaml . | nindent 2 }} {{- end }} + - apiGroups: + - "" + resources: + - "events" + verbs: + - "create" + - "patch" + - apiGroups: + - coordination.k8s.io + resources: + - leases + verbs: + - get + - list + - watch + - create + - update + - patch + - delete - apiGroups: - argoproj.io verbs: diff --git a/charts/argo-events/templates/argo-events-roles.yaml b/charts/argo-events/templates/argo-events-roles.yaml index 7406073c..b8e81eff 100644 --- a/charts/argo-events/templates/argo-events-roles.yaml +++ b/charts/argo-events/templates/argo-events-roles.yaml @@ -30,6 +30,25 @@ rules: {{- with .Values.additionalServiceAccountRules }} {{- toYaml . | nindent 2 }} {{- end }} + - apiGroups: + - "" + resources: + - "events" + verbs: + - "create" + - "patch" + - apiGroups: + - coordination.k8s.io + resources: + - leases + verbs: + - get + - list + - watch + - create + - update + - patch + - delete - apiGroups: - argoproj.io verbs: