diff options
author | Dileep Ranganathan <dileep.ranganathan@intel.com> | 2019-06-13 00:26:10 -0700 |
---|---|---|
committer | Dileep Ranganathan <dileep.ranganathan@intel.com> | 2019-06-13 00:26:10 -0700 |
commit | e7cf41ad23960f23c03a553f62f5d710054ede23 (patch) | |
tree | cdc6c1d6b0a5079f7c166a69ad03d68d229228f3 /vnfs/DAaaS/deploy/collection/charts/prometheus/templates/_helpers.tpl | |
parent | 9610eedd1351ede91d417412740b2560525a1fab (diff) |
Add RBAC for prometheus instance
Fixed issue of prometheus throwing unauthorized rbac error.
Change-Id: I984bf637bf464803c35bfb32bf09b2974fec9053
Issue-ID: ONAPARC-506
Signed-off-by: Dileep Ranganathan <dileep.ranganathan@intel.com>
Diffstat (limited to 'vnfs/DAaaS/deploy/collection/charts/prometheus/templates/_helpers.tpl')
-rw-r--r-- | vnfs/DAaaS/deploy/collection/charts/prometheus/templates/_helpers.tpl | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/vnfs/DAaaS/deploy/collection/charts/prometheus/templates/_helpers.tpl b/vnfs/DAaaS/deploy/collection/charts/prometheus/templates/_helpers.tpl index 1ac77dd8..17b7e7bd 100644 --- a/vnfs/DAaaS/deploy/collection/charts/prometheus/templates/_helpers.tpl +++ b/vnfs/DAaaS/deploy/collection/charts/prometheus/templates/_helpers.tpl @@ -44,4 +44,14 @@ heritage: {{ .Release.Service | quote }} {{- if .Values.commonLabels}} {{ toYaml .Values.commonLabels }} {{- end }} -{{- end }}
\ No newline at end of file +{{- end }} + + +{{/* Create the name of prometheus service account to use */}} +{{- define "prometheus.serviceAccountName" -}} +{{- if .Values.prometheus.serviceAccount.create -}} + {{ default (include "prometheus.fullname" .) .Values.prometheus.serviceAccount.name }} +{{- else -}} + {{ default "default" .Values.prometheus.serviceAccount.name }} +{{- end -}} +{{- end -}}
\ No newline at end of file |