rancher-charts/charts/rancher-project-monitoring/0.2.0+up0.2.1/templates/prometheus/serviceaccount.yaml

21 lines
861 B
YAML

{{- if and .Values.prometheus.enabled .Values.prometheus.serviceAccount.create }}
apiVersion: v1
kind: ServiceAccount
metadata:
name: {{ template "project-prometheus-stack.prometheus.serviceAccountName" . }}
namespace: {{ template "project-prometheus-stack.namespace" . }}
labels:
app: {{ template "project-prometheus-stack.name" . }}-prometheus
app.kubernetes.io/name: {{ template "project-prometheus-stack.name" . }}-prometheus
app.kubernetes.io/component: prometheus
{{ include "project-prometheus-stack.labels" . | indent 4 }}
{{- if .Values.prometheus.serviceAccount.annotations }}
annotations:
{{ toYaml .Values.prometheus.serviceAccount.annotations | indent 4 }}
{{- end }}
{{- if .Values.global.imagePullSecrets }}
imagePullSecrets:
{{ include "project-prometheus-stack.imagePullSecrets" . | trim | indent 2 }}
{{- end }}
{{- end }}