{{- if .Values.ingress.enabled }} apiVersion: networking.k8s.io/v1 kind: Ingress metadata: name: onelab-revproxy labels: {{- include "onelab.labels" . | nindent 4 }} annotations: argocd.argoproj.io/sync-wave: {{ .Values.syncWaves.apps | quote }} {{- with .Values.ingress.annotations }} {{- toYaml . | nindent 4 }} {{- end }} spec: {{- if .Values.ingress.className }} ingressClassName: {{ .Values.ingress.className | quote }} {{- end }} {{- if .Values.ingress.tls }} tls: - hosts: - {{ .Values.ingress.host | quote }} secretName: {{ if .Values.ingress.tlsSecretName }}{{ .Values.ingress.tlsSecretName | quote }}{{ else }}{{ printf "%s-tls" .Release.Name | quote }}{{ end }} {{- end }} rules: - host: {{ .Values.ingress.host | quote }} http: paths: - path: {{ .Values.ingress.path | quote }} pathType: {{ .Values.ingress.pathType | quote }} backend: service: name: revproxy port: name: http {{- end }}