apiVersion: v1
kind: Service
metadata:
  name: {{ include "pihole-exporter.fullname" . }}
  labels:
    k8s-app: pihole-metrics
{{ include "pihole-exporter.labels" . | indent 4 }}
spec:
  type: {{ .Values.service.type }}
  ports:
    - port: {{ .Values.service.port }}
      targetPort: {{ .Values.service.port }}
      protocol: TCP
      name: pihole-metrics
  selector:
    app.kubernetes.io/name: {{ include "pihole-exporter.name" . }}
    app.kubernetes.io/instance: {{ .Release.Name }}
