oc-k8s/opencloud/charts/loki/templates/ingester/service-ingester-headless.yaml

36 lines
1.1 KiB
YAML
Raw Normal View History

2024-12-16 14:55:43 +01:00
{{- $isDistributed := eq (include "loki.deployment.isDistributed" .) "true" -}}
{{- if and $isDistributed (or (not .Values.ingester.zoneAwareReplication.enabled) .Values.ingester.zoneAwareReplication.migration.enabled) }}
apiVersion: v1
kind: Service
metadata:
name: {{ include "loki.ingesterFullname" . }}-headless
namespace: {{ .Release.Namespace }}
labels:
{{- include "loki.ingesterSelectorLabels" . | nindent 4 }}
prometheus.io/service-monitor: "false"
annotations:
{{- with .Values.loki.serviceAnnotations }}
{{- toYaml . | nindent 4}}
{{- end }}
{{- with .Values.ingester.serviceAnnotations }}
{{- toYaml . | nindent 4}}
{{- end }}
spec:
type: ClusterIP
clusterIP: None
ports:
- name: http-metrics
port: 3100
targetPort: http-metrics
protocol: TCP
- name: grpc
port: 9095
targetPort: grpc
protocol: TCP
{{- if .Values.ingester.appProtocol.grpc }}
appProtocol: {{ .Values.ingester.appProtocol.grpc }}
{{- end }}
selector:
{{- include "loki.ingesterSelectorLabels" . | nindent 4 }}
{{- end -}}