apiVersion: monitoring.coreos.com/v1
kind: ServiceMonitor
metadata:
  name:  {{ include "pipeline.fullname" . }}-monitoring
spec:
  endpoints:
  - interval: 60s
    port: http
    scrapeTimeout: 60s
    path: /metrics
    relabelings:
    - sourceLabels: []
      targetLabel: cluster_id
      replacement: {{ .Values.pipeline.targetClusterId | quote }}
  selector:
    matchLabels:
      {{- include "pipeline.selectorLabels" . | nindent 6 }}
