Просмотр исходного кода

fix(chart): grant provider access to both secretmanager CRDs

Moritz Johner 1 месяц назад
Родитель
Сommit
96b25a5db4

+ 1 - 2
deploy/charts/external-secrets/templates/provider-rbac.yaml

@@ -18,6 +18,7 @@ rules:
     - "fakes"
     - "kubernetes"
     - "secretmanagers"
+    - "secretsmanagers"
     - "parameterstores"
     verbs:
     - "get"
@@ -98,5 +99,3 @@ subjects:
 {{- end }}
 {{- end }}
 {{- end }}
-
-

+ 18 - 0
deploy/charts/external-secrets/tests/provider_rbac_test.yaml

@@ -20,3 +20,21 @@ tests:
       - contains:
           path: rules[0].resources
           content: secretmanagers
+  - it: should grant aws providers access to secretsmanager configs
+    set:
+      providers:
+        enabled: true
+        list:
+          - name: aws
+            type: aws
+            enabled: true
+            image:
+              repository: ghcr.io/external-secrets/provider-aws
+              tag: test
+    documentIndex: 0
+    asserts:
+      - isKind:
+          of: ClusterRole
+      - contains:
+          path: rules[0].resources
+          content: secretsmanagers