apiVersion: v1
kind: Service
metadata:
  name: {{ template "mariadb-galera.fullname" . }}-headless
  labels: {{- include "mariadb-galera.labels" . | nindent 4 }}
  {{- if .Values.service.headless.annotations }}
  annotations: {{- include "mariadb-galera.tplValue" (dict "value" .Values.service.headless.annotations "context" $) | nindent 4 }}
  {{- end }}
spec:
  type: ClusterIP
  clusterIP: None
  ports:
    - name: galera
      port: 4567
      targetPort: galera
    - name: ist
      port: 4568
      targetPort: ist
    - name: sst
      port: 4444
      targetPort: sst
  selector: {{- include "mariadb-galera.matchLabels" . | nindent 4 }}
