apiVersion: v1
kind: Service
metadata:
  name: {{ include "etcd.fullname" . }}-headless
  labels: {{- include "etcd.labels" . | nindent 4 }}
  annotations:
    service.alpha.kubernetes.io/tolerate-unready-endpoints: "true"
spec:
  type: ClusterIP
  clusterIP: None
  ports:
    - name: client
      port: {{ .Values.service.port  }}
      targetPort: client
    - name: peer
      port: {{ .Values.service.peerPort  }}
      targetPort: peer
  selector: {{- include "etcd.matchLabels" . | nindent 4 }}
