blob: 883d8a48f6dd0db1f3be4fdd754ed4269d1a33fc [file] [log] [blame]
Mohammed Naserb8eccd22023-02-10 05:55:56 +00001{{- if .Values.ingress.dashboard.host }}
2---
3apiVersion: {{ include "capabilities.ingress.apiVersion" . }}
4kind: Ingress
5metadata:
6 name: {{ template "clusterName" . }}-dashboard
Mohammed Naser65cda132024-05-02 14:34:08 -04007 namespace: {{ .Release.Namespace }} # namespace:cluster
Mohammed Naserb8eccd22023-02-10 05:55:56 +00008 {{- if .Values.ingress.dashboard.annotations }}
9 annotations: {{- toYaml .Values.ingress.dashboard.annotations | nindent 4 }}
10 {{- end }}
11spec:
12 rules:
13 - host: {{ .Values.ingress.dashboard.host.name }}
14 http:
15 paths:
16 - path: {{ .Values.ingress.dashboard.host.path | default "/" }}
17 backend:
18{{- if (eq "networking.k8s.io/v1" (include "capabilities.ingress.apiVersion" .)) }}
19 service:
20 name: rook-ceph-mgr-dashboard
21 port:
22 {{- if .Values.cephClusterSpec.dashboard.ssl }}
23 name: https-dashboard
24 {{- else }}
25 name: http-dashboard
26 {{- end }}
27 pathType: Prefix
28{{- else }}
29 serviceName: rook-ceph-mgr-dashboard
30 {{- if .Values.cephClusterSpec.dashboard.ssl }}
31 servicePort: https-dashboard
32 {{- else }}
33 servicePort: http-dashboard
34 {{- end }}
35{{- end }}
36 {{- if .Values.ingress.dashboard.ingressClassName }}
37 ingressClassName: {{ .Values.ingress.dashboard.ingressClassName }}
38 {{- end }}
39 {{- if .Values.ingress.dashboard.tls }}
40 tls: {{- toYaml .Values.ingress.dashboard.tls | nindent 4 }}
41 {{- end }}
42{{- end }}