From e638d92d1f48e0747fae96cd0606a52525ce9bf8 Mon Sep 17 00:00:00 2001 From: Srivahni Date: Fri, 22 Mar 2019 16:22:35 -0700 Subject: Move Prometheus-operator to operator package Change-Id: I9f3b1a67c62303e40c46fa9d28abe0339e248ed6 Issue-ID: ONAPARC-444 Signed-off-by: Srivahni --- .../templates/grafana/servicemonitor.yaml | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 vnfs/DAaaS/operator/charts/prometheus-operator/templates/grafana/servicemonitor.yaml (limited to 'vnfs/DAaaS/operator/charts/prometheus-operator/templates/grafana/servicemonitor.yaml') diff --git a/vnfs/DAaaS/operator/charts/prometheus-operator/templates/grafana/servicemonitor.yaml b/vnfs/DAaaS/operator/charts/prometheus-operator/templates/grafana/servicemonitor.yaml new file mode 100644 index 00000000..954a842c --- /dev/null +++ b/vnfs/DAaaS/operator/charts/prometheus-operator/templates/grafana/servicemonitor.yaml @@ -0,0 +1,21 @@ +{{- if and .Values.grafana.enabled .Values.grafana.serviceMonitor.selfMonitor }} +apiVersion: {{ printf "%s/v1" (.Values.prometheusOperator.crdApiGroup | default "monitoring.coreos.com") }} +kind: ServiceMonitor +metadata: + name: {{ template "prometheus-operator.fullname" . }}-grafana + labels: + app: {{ template "prometheus-operator.name" . }}-grafana +{{ include "prometheus-operator.labels" . | indent 4 }} +spec: + selector: + matchLabels: + app: grafana + release: {{ .Release.Name | quote }} + namespaceSelector: + matchNames: + - {{ .Release.Namespace | quote }} + endpoints: + - port: service + interval: 30s + path: "{{ trimSuffix "/" .Values.grafana.ingress.path }}/metrics" +{{- end }} -- cgit 1.2.3-korg