aboutsummaryrefslogtreecommitdiffstats
path: root/vnfs/DAaaS/collection/charts/prometheus/templates/servicemonitor.yaml
diff options
context:
space:
mode:
Diffstat (limited to 'vnfs/DAaaS/collection/charts/prometheus/templates/servicemonitor.yaml')
-rw-r--r--vnfs/DAaaS/collection/charts/prometheus/templates/servicemonitor.yaml29
1 files changed, 29 insertions, 0 deletions
diff --git a/vnfs/DAaaS/collection/charts/prometheus/templates/servicemonitor.yaml b/vnfs/DAaaS/collection/charts/prometheus/templates/servicemonitor.yaml
new file mode 100644
index 00000000..47a911c6
--- /dev/null
+++ b/vnfs/DAaaS/collection/charts/prometheus/templates/servicemonitor.yaml
@@ -0,0 +1,29 @@
+{{- if .Values.prometheus.additionalServiceMonitors }}
+apiVersion: v1
+kind: List
+items:
+{{- range .Values.prometheus.additionalServiceMonitors }}
+ - apiVersion: "monitoring.coreos.com/v1"
+ kind: ServiceMonitor
+ metadata:
+ name: {{ .name }}
+ labels:
+ app: {{ template "prometheus.name" $ }}-prometheus
+{{ include "prometheus.labels" $ | indent 8 }}
+ {{- if .additionalLabels }}
+{{ toYaml .additionalLabels | indent 8 }}
+ {{- end }}
+ spec:
+ endpoints:
+{{ toYaml .endpoints | indent 8 }}
+ {{- if .jobLabel }}
+ jobLabel: {{ .jobLabel }}
+ {{- end }}
+ {{- if .namespaceSelector }}
+ namespaceSelector:
+{{ toYaml .namespaceSelector | indent 8 }}
+ {{- end }}
+ selector:
+{{ toYaml .selector | indent 8 }}
+{{- end }}
+{{- end }}