| Giorgi Lekveishvili | 4ec4c02 | 2024-08-17 15:09:24 +0400 | [diff] [blame] | 1 | {{- if .Values.ingress.enabled }} |
| Giorgi Lekveishvili | 4ec4c02 | 2024-08-17 15:09:24 +0400 | [diff] [blame] | 2 | apiVersion: networking.k8s.io/v1 |
| Giorgi Lekveishvili | 4ec4c02 | 2024-08-17 15:09:24 +0400 | [diff] [blame] | 3 | kind: Ingress |
| 4 | metadata: |
| 5 | name: longhorn-ingress |
| 6 | namespace: {{ include "release_namespace" . }} |
| 7 | labels: {{- include "longhorn.labels" . | nindent 4 }} |
| 8 | app: longhorn-ingress |
| 9 | annotations: |
| 10 | {{- if .Values.ingress.secureBackends }} |
| 11 | ingress.kubernetes.io/secure-backends: "true" |
| 12 | {{- end }} |
| 13 | {{- range $key, $value := .Values.ingress.annotations }} |
| 14 | {{ $key }}: {{ $value | quote }} |
| 15 | {{- end }} |
| 16 | spec: |
| Giorgi Lekveishvili | 193b7c0 | 2025-05-22 16:21:37 +0400 | [diff] [blame^] | 17 | {{- if .Values.ingress.ingressClassName }} |
| Giorgi Lekveishvili | 4ec4c02 | 2024-08-17 15:09:24 +0400 | [diff] [blame] | 18 | ingressClassName: {{ .Values.ingress.ingressClassName }} |
| 19 | {{- end }} |
| 20 | rules: |
| 21 | - host: {{ .Values.ingress.host }} |
| 22 | http: |
| 23 | paths: |
| 24 | - path: {{ default "" .Values.ingress.path }} |
| Giorgi Lekveishvili | 193b7c0 | 2025-05-22 16:21:37 +0400 | [diff] [blame^] | 25 | pathType: {{ default "ImplementationSpecific" .Values.ingress.pathType }} |
| Giorgi Lekveishvili | 4ec4c02 | 2024-08-17 15:09:24 +0400 | [diff] [blame] | 26 | backend: |
| Giorgi Lekveishvili | 4ec4c02 | 2024-08-17 15:09:24 +0400 | [diff] [blame] | 27 | service: |
| 28 | name: longhorn-frontend |
| 29 | port: |
| 30 | number: 80 |
| Giorgi Lekveishvili | 4ec4c02 | 2024-08-17 15:09:24 +0400 | [diff] [blame] | 31 | {{- if .Values.ingress.tls }} |
| 32 | tls: |
| 33 | - hosts: |
| 34 | - {{ .Values.ingress.host }} |
| 35 | secretName: {{ .Values.ingress.tlsSecret }} |
| 36 | {{- end }} |
| 37 | {{- end }} |