Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix KEDA crashes when using cert-manager certificates and restricted secret access #518

Merged
8 changes: 5 additions & 3 deletions keda/templates/manager/role.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{{- if and .Values.certificates.autoGenerated ( not .Values.certificates.certManager.enabled ) }}
{{- if or (and .Values.certificates.autoGenerated (not .Values.certificates.certManager.enabled)) (and .Values.permissions.operator.restrict.secret .Values.certificates.certManager.enabled) }}
apiVersion: rbac.authorization.k8s.io/v1
gjacquet marked this conversation as resolved.
Show resolved Hide resolved
kind: Role
metadata:
Expand All @@ -17,11 +17,13 @@ rules:
resources:
- secrets
verbs:
{{- if not (and .Values.permissions.operator.restrict.secret .Values.certificates.certManager.enabled) }}
- create
gjacquet marked this conversation as resolved.
Show resolved Hide resolved
- delete
- get
- list
- patch
- update
{{- end }}
- watch
- get
- list
{{- end -}}
2 changes: 1 addition & 1 deletion keda/templates/manager/rolebinding.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{{- if and .Values.certificates.autoGenerated ( not .Values.certificates.certManager.enabled ) }}
{{- if or (and .Values.certificates.autoGenerated (not .Values.certificates.certManager.enabled)) (and .Values.permissions.operator.restrict.secret .Values.certificates.certManager.enabled) }}
apiVersion: rbac.authorization.k8s.io/v1
gjacquet marked this conversation as resolved.
Show resolved Hide resolved
kind: RoleBinding
metadata:
Expand Down
Loading