{{- if .Values.api.enabled }} apiVersion: v1 kind: Service metadata: name: {{ include "datacenter-docs.api.fullname" . }} labels: {{- include "datacenter-docs.api.labels" . | nindent 4 }} spec: type: {{ .Values.api.service.type }} ports: - port: {{ .Values.api.service.port }} targetPort: http protocol: TCP name: http selector: {{- include "datacenter-docs.api.selectorLabels" . | nindent 4 }} {{- end }}