apiVersion: v1
kind: Service
metadata:
  name: {{ template "aerospike.fullname" . }}-mesh
  labels:
    app: {{ template "aerospike.name" . }}
    chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
    release: {{ .Release.Name }}
    heritage: {{ .Release.Service }}
  annotations:
    service.alpha.kubernetes.io/tolerate-unready-endpoints: "true"
    {{- range $key, $value := .Values.meshService.annotations }}
    {{ $key }}: {{ $value | quote }}
    {{- end }}
spec:
  clusterIP: None
  type: ClusterIP
  ports:
    - port: 3002
      protocol: TCP
      name: aerospike-mesh
  selector:
    app: {{ template "aerospike.name" . }}
    release: {{ .Release.Name }}
