merlimat closed pull request #3082: WIP: option to not to use rbac in helm 
deployment
URL: https://github.com/apache/pulsar/pull/3082
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git 
a/deployment/kubernetes/helm/pulsar/templates/prometheus-deployment.yaml 
b/deployment/kubernetes/helm/pulsar/templates/prometheus-deployment.yaml
index 58a143d5b1..e72299303c 100644
--- a/deployment/kubernetes/helm/pulsar/templates/prometheus-deployment.yaml
+++ b/deployment/kubernetes/helm/pulsar/templates/prometheus-deployment.yaml
@@ -55,7 +55,9 @@ spec:
       tolerations:
 {{ toYaml .Values.prometheus.tolerations | indent 8 }}
     {{- end }}
+    {{- if .Values.prometheus_rbac }}
       serviceAccount: "{{ template "pulsar.fullname" . }}-{{ 
.Values.prometheus.component }}"
+    {{- end }}
       terminationGracePeriodSeconds: {{ .Values.prometheus.gracePeriod }}
       containers:
       - name: "{{ template "pulsar.fullname" . }}-{{ 
.Values.prometheus.component }}"
diff --git a/deployment/kubernetes/helm/pulsar/templates/prometheus-rbac.yaml 
b/deployment/kubernetes/helm/pulsar/templates/prometheus-rbac.yaml
index 04c1b4335e..a25bbb9d7b 100644
--- a/deployment/kubernetes/helm/pulsar/templates/prometheus-rbac.yaml
+++ b/deployment/kubernetes/helm/pulsar/templates/prometheus-rbac.yaml
@@ -18,6 +18,7 @@
 #
 
 {{- if .Values.extra.monitoring }}
+{{- if .Values.prometheus_rbac }}
 apiVersion: rbac.authorization.k8s.io/v1beta1
 kind: ClusterRole
 metadata:
@@ -55,3 +56,4 @@ subjects:
   name: "{{ template "pulsar.fullname" . }}-{{ .Values.prometheus.component }}"
   namespace: {{ .Values.namespace }}
 {{- end }}
+{{- end }}
diff --git a/deployment/kubernetes/helm/pulsar/values-mini.yaml 
b/deployment/kubernetes/helm/pulsar/values-mini.yaml
index 94a5bc38c6..e8977ce17c 100644
--- a/deployment/kubernetes/helm/pulsar/values-mini.yaml
+++ b/deployment/kubernetes/helm/pulsar/values-mini.yaml
@@ -31,6 +31,8 @@ persistence: no
 ## will be deployed with emptyDir
 prometheus_persistence: no
 
+prometheus_rbac: yes
+
 ## which extra components to deploy
 extra:
   # Pulsar proxy
diff --git a/deployment/kubernetes/helm/pulsar/values.yaml 
b/deployment/kubernetes/helm/pulsar/values.yaml
index fe237e8ae2..982f095df3 100644
--- a/deployment/kubernetes/helm/pulsar/values.yaml
+++ b/deployment/kubernetes/helm/pulsar/values.yaml
@@ -31,6 +31,8 @@ persistence: no
 ## will be deployed with emptyDir
 prometheus_persistence: yes
 
+prometheus_rbac: yes
+
 ## which extra components to deploy
 extra:
   # Pulsar proxy


 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to