Skip to content

Commit

Permalink
agent: configurable autowire and metrics RBAC (kedacore#56)
Browse files Browse the repository at this point in the history
Signed-off-by: Jan Wozniak <wozniak.jan@gmail.com>
wozniakjan authored and Kedify Bot committed Dec 17, 2024
1 parent 3895d62 commit f3332d3
Showing 2 changed files with 17 additions and 5 deletions.
10 changes: 5 additions & 5 deletions kedify-agent/templates/agent-deployment.yaml
Original file line number Diff line number Diff line change
@@ -47,14 +47,14 @@ spec:
value: /helm/repository/repositories.yaml
- name: HELM_REPOSITORY_CACHE
value: /helm/charts
{{- if .Values.agent.noColor }}
{{- if .Values.agent.noColor }}
- name: NO_COLOR
value: {{ .Values.agent.noColor | quote }}
{{- end }}
{{- if .Values.agent.noBanner }}
{{- end }}
{{- if .Values.agent.noBanner }}
- name: NO_BANNER
value: {{ .Values.agent.noBanner | quote }}
{{- end }}
{{- end }}
- name: RBAC_READ_NODES
value: {{ .Values.agent.rbac.readNodes | quote }}
- name: RBAC_READ_PODS
@@ -73,7 +73,7 @@ spec:
value: {{ or .Values.agent.rbac.shouldBeAbleToInstallKeda .Values.agent.rbac.shouldBeAbleToInstallHttpAddon | quote }}
- name: RBAC_MANAGE_HELM
value: {{ or .Values.agent.rbac.shouldBeAbleToInstallKeda .Values.agent.rbac.shouldBeAbleToInstallHttpAddon | quote }}
- name: RBAC_MANAGE_INGRESS_AUTOWIRE
- name: RBAC_MANAGE_INGRESS_AUTO_WIRE
value: {{ .Values.agent.rbac.ingressAutoWire | quote }}
- name: RBAC_MANAGE_KEDIFY_CONFIG
value: {{ .Values.agent.rbac.kedifyConfig | quote }}
12 changes: 12 additions & 0 deletions kedify-agent/templates/agent-rbac.yaml
Original file line number Diff line number Diff line change
@@ -319,6 +319,18 @@ rules:
- kedify-proxy
{{- end }}

{{- if .Values.agent.rbac.readMetrics }}
- apiGroups:
- apps
resources:
- deployments
- statefulsets
verbs:
- get
- list
- watch
{{- end }}

{{- if .Values.agent.rbac.uninstall }}
# Kedify needs to be able to uninstall itself
- apiGroups:

0 comments on commit f3332d3

Please sign in to comment.