{{- include "nplus.init" $ -}}
{{- $name := (print .component.prefix "sharepoint-cluster") -}}
{{- if (.Values.clusterService).enabled }}
{{- if (.Values.clusterService).contextPath }}
{{- include "nplus.ingress" (list . $name) | nindent 0 }}
      - path: {{ .Values.clusterService.contextPath }}
        pathType: Prefix
        backend:
          service:
            name: {{ $name }}
            port: 
              name: {{ include "nplus.backendProtocol" . }}
{{- else }}
# kind: Ingress
# Not Generating any Ingress for {{ $name }} as the context Path is unset on component {{ .component.fullName }}
# clusterService: {{ .Values.clusterService }}
{{- end }}
{{- else }}
# kind: Ingress
# Not Generating any Ingress for {{ $name }} as the Cluster Service is not enabled on component {{ .component.fullName }}
# clusterService: {{ .Values.clusterService }}
{{- end }}