{{- if and (not .Values.enableNodeFeatureApi) .Values.master.enable }} apiVersion: v1 kind: Service metadata: name: {{ include "node-feature-discovery.fullname" . }}-master namespace: {{ include "node-feature-discovery.namespace" . }} labels: {{- include "node-feature-discovery.labels" . | nindent 4 }} role: master spec: type: {{ .Values.master.service.type }} ports: - port: {{ .Values.master.service.port | default "8080" }} targetPort: grpc protocol: TCP name: grpc selector: {{- include "node-feature-discovery.selectorLabels" . | nindent 4 }} role: master {{- end}}