diff --git a/templates/ingress/ingress.yaml b/templates/ingress/ingress.yaml index 0b23cb43c..f2314716e 100644 --- a/templates/ingress/ingress.yaml +++ b/templates/ingress/ingress.yaml @@ -2,6 +2,7 @@ {{- $ingress := .Values.expose.ingress -}} {{- $tls := .Values.expose.tls -}} {{- if eq .Values.expose.ingress.controller "gce" }} + {{- $_ := set . "path_type" "ImplementationSpecific" -}} {{- $_ := set . "portal_path" "/*" -}} {{- $_ := set . "api_path" "/api/*" -}} {{- $_ := set . "service_path" "/service/*" -}} @@ -9,6 +10,7 @@ {{- $_ := set . "chartrepo_path" "/chartrepo/*" -}} {{- $_ := set . "controller_path" "/c/*" -}} {{- else if eq .Values.expose.ingress.controller "ncp" }} + {{- $_ := set . "path_type" "Prefix" -}} {{- $_ := set . "portal_path" "/.*" -}} {{- $_ := set . "api_path" "/api/.*" -}} {{- $_ := set . "service_path" "/service/.*" -}} @@ -16,6 +18,7 @@ {{- $_ := set . "chartrepo_path" "/chartrepo/.*" -}} {{- $_ := set . "controller_path" "/c/.*" -}} {{- else }} + {{- $_ := set . "path_type" "Prefix" -}} {{- $_ := set . "portal_path" "/" -}} {{- $_ := set . "api_path" "/api/" -}} {{- $_ := set . "service_path" "/service/" -}} @@ -94,42 +97,42 @@ spec: servicePort: {{ template "harbor.portal.servicePort" . }} {{- else }} - path: {{ .api_path }} - pathType: Prefix + pathType: {{ .path_type }} backend: service: name: {{ template "harbor.core" . }} port: number: {{ template "harbor.core.servicePort" . }} - path: {{ .service_path }} - pathType: Prefix + pathType: {{ .path_type }} backend: service: name: {{ template "harbor.core" . }} port: number: {{ template "harbor.core.servicePort" . }} - path: {{ .v2_path }} - pathType: Prefix + pathType: {{ .path_type }} backend: service: name: {{ template "harbor.core" . }} port: number: {{ template "harbor.core.servicePort" . }} - path: {{ .chartrepo_path }} - pathType: Prefix + pathType: {{ .path_type }} backend: service: name: {{ template "harbor.core" . }} port: number: {{ template "harbor.core.servicePort" . }} - path: {{ .controller_path }} - pathType: Prefix + pathType: {{ .path_type }} backend: service: name: {{ template "harbor.core" . }} port: number: {{ template "harbor.core.servicePort" . }} - path: {{ .portal_path }} - pathType: Prefix + pathType: {{ .path_type }} backend: service: name: {{ template "harbor.portal" . }}