2025-01-03 14:18:54 +01:00
|
|
|
{{- if and .Values.prometheus.enabled .Values.prometheus.servicemonitor.enabled }}
|
|
|
|
apiVersion: monitoring.coreos.com/v1
|
|
|
|
kind: ServiceMonitor
|
|
|
|
metadata:
|
|
|
|
name: {{ include "autopush.fullname" . }}
|
|
|
|
labels:
|
|
|
|
{{- include "autopush.labels" . | nindent 4 }}
|
|
|
|
{{- with .Values.prometheus.servicemonitor.labels }}
|
|
|
|
{{- toYaml . | nindent 4 }}
|
|
|
|
{{- end }}
|
|
|
|
spec:
|
|
|
|
selector:
|
|
|
|
matchLabels:
|
|
|
|
{{- include "autopush.selectorLabels" . | nindent 6 }}
|
2025-01-22 21:29:58 +01:00
|
|
|
app.kubernetes.io/metrics: "true"
|
2025-01-03 14:18:54 +01:00
|
|
|
endpoints:
|
|
|
|
- port: metrics
|
|
|
|
{{- end }}
|