From 260d287f4a67fda903dd86f2ae89e2cc60c0cda9 Mon Sep 17 00:00:00 2001 From: Amit Lichtenberg Date: Sun, 14 Jul 2024 15:51:43 +0300 Subject: [PATCH] Bugfixes in intents-operator RBAC for AWS IAM roles anywhere --- credentials-operator/templates/rbac-certmgr.yaml | 4 +--- .../intents-operator-leader-election-rolebinding.yaml | 4 ++-- intents-operator/templates/rbac-certmgr.yaml | 4 +--- 3 files changed, 4 insertions(+), 8 deletions(-) diff --git a/credentials-operator/templates/rbac-certmgr.yaml b/credentials-operator/templates/rbac-certmgr.yaml index 09e3e329..80f9e681 100644 --- a/credentials-operator/templates/rbac-certmgr.yaml +++ b/credentials-operator/templates/rbac-certmgr.yaml @@ -3,7 +3,6 @@ apiVersion: rbac.authorization.k8s.io/v1 kind: Role metadata: name: creds-operator-certificaterequest-creator - namespace: otterize-system rules: - apiGroups: ["cert-manager.io"] resources: ["certificaterequests"] @@ -13,7 +12,6 @@ apiVersion: rbac.authorization.k8s.io/v1 kind: RoleBinding metadata: name: credentials-operator-certificaterequest - namespace: otterize-system roleRef: apiGroup: rbac.authorization.k8s.io kind: Role @@ -21,6 +19,6 @@ roleRef: subjects: - kind: ServiceAccount name: credentials-operator-controller-manager - namespace: otterize-system + namespace: {{ .Release.Namespace }} --- {{- end }} \ No newline at end of file diff --git a/intents-operator/templates/intents-operator-leader-election-rolebinding.yaml b/intents-operator/templates/intents-operator-leader-election-rolebinding.yaml index 000749fb..b952ee62 100644 --- a/intents-operator/templates/intents-operator-leader-election-rolebinding.yaml +++ b/intents-operator/templates/intents-operator-leader-election-rolebinding.yaml @@ -1,7 +1,7 @@ apiVersion: rbac.authorization.k8s.io/v1 kind: RoleBinding metadata: - name: otterize-intents-operator-leader-election-rolebinding + name: otterize-intents-operator-leader-election-rolebinding-v2 namespace: {{ .Release.Namespace }} labels: {{- with .Values.global.commonLabels }} @@ -16,7 +16,7 @@ metadata: roleRef: apiGroup: rbac.authorization.k8s.io kind: Role - name: intents-operator-leader-election-role + name: otterize-intents-operator-leader-election-role subjects: - kind: ServiceAccount name: intents-operator-controller-manager diff --git a/intents-operator/templates/rbac-certmgr.yaml b/intents-operator/templates/rbac-certmgr.yaml index cf473ba0..d51a8de1 100644 --- a/intents-operator/templates/rbac-certmgr.yaml +++ b/intents-operator/templates/rbac-certmgr.yaml @@ -3,7 +3,6 @@ apiVersion: rbac.authorization.k8s.io/v1 kind: Role metadata: name: intents-operator-certificaterequest-creator - namespace: otterize-system rules: - apiGroups: ["cert-manager.io"] resources: ["certificaterequests"] @@ -13,7 +12,6 @@ apiVersion: rbac.authorization.k8s.io/v1 kind: RoleBinding metadata: name: intents-operator-certificaterequest - namespace: otterize-system roleRef: apiGroup: rbac.authorization.k8s.io kind: Role @@ -21,5 +19,5 @@ roleRef: subjects: - kind: ServiceAccount name: intents-operator-controller-manager - namespace: otterize-system + namespace: {{ .Release.Namespace }} {{- end }} \ No newline at end of file