{{- if and .Values.dynamicConfig.enabled .Values.dynamicConfig.upload.enabled .Values.dynamicConfig.upload.ingress.enabled -}}
|
|
{{- $fullName := include "collabora-online.fullname" . -}}
|
|
{{- $svcPort := .Values.dynamicConfig.upload.service.port -}}
|
|
apiVersion: networking.k8s.io/v1
|
|
kind: Ingress
|
|
metadata:
|
|
name: {{ $fullName }}-dynconfig-upload
|
|
labels:
|
|
{{- include "collabora-online.labels" . | nindent 4 }}
|
|
{{- with .Values.dynamicConfig.upload.ingress.annotations }}
|
|
annotations:
|
|
{{- toYaml . | nindent 4 }}
|
|
{{- end }}
|
|
spec:
|
|
{{- if .Values.dynamicConfig.upload.ingress.className }}
|
|
ingressClassName: {{ .Values.dynamicConfig.upload.ingress.className }}
|
|
{{- end }}
|
|
{{- if .Values.dynamicConfig.upload.ingress.tls }}
|
|
tls:
|
|
{{- range .Values.dynamicConfig.upload.ingress.tls }}
|
|
- hosts:
|
|
{{- range .hosts }}
|
|
- {{ . | quote }}
|
|
{{- end }}
|
|
secretName: {{ .secretName }}
|
|
{{- end }}
|
|
{{- end }}
|
|
rules:
|
|
{{- range .Values.dynamicConfig.upload.ingress.hosts }}
|
|
- host: {{ .host | quote }}
|
|
http:
|
|
paths:
|
|
{{- range .paths }}
|
|
- path: {{ .path }}
|
|
pathType: {{ .pathType }}
|
|
backend:
|
|
service:
|
|
name: {{ $fullName }}-dynconfig
|
|
port:
|
|
number: {{ $svcPort }}
|
|
{{- end }}
|
|
{{- end }}
|
|
{{- end }}
|