Files
HetznerTerra/infrastructure/charts/promtail/templates/service-metrics.yaml
T

26 lines
697 B
YAML
Raw Normal View History

2026-05-04 10:49:46 +00:00
{{- if or .Values.serviceMonitor.enabled .Values.service.enabled }}
apiVersion: v1
kind: Service
metadata:
name: {{ include "promtail.fullname" . }}-metrics
namespace: {{ include "promtail.namespaceName" . }}
labels:
{{- include "promtail.labels" . | nindent 4 }}
{{- with .Values.service.labels }}
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .Values.service.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
clusterIP: None
ports:
- name: http-metrics
port: {{ .Values.config.serverPort }}
targetPort: http-metrics
protocol: TCP
selector:
{{- include "promtail.selectorLabels" . | nindent 4 }}
{{- end }}