ci
This commit is contained in:
45
talks-slides-dist/templates/ingress.yaml
Normal file
45
talks-slides-dist/templates/ingress.yaml
Normal file
@@ -0,0 +1,45 @@
|
||||
{{- if .Values.slides.ingress.enabled -}}
|
||||
{{- $tlsOn := or .Values.slides.ingress.tls.enabled .Values.slides.ingress.certManager.enabled -}}
|
||||
apiVersion: networking.k8s.io/v1
|
||||
kind: Ingress
|
||||
metadata:
|
||||
name: {{ include "talks-slides.fullname" . }}
|
||||
labels:
|
||||
{{- include "talks-slides.labels" . | nindent 4 }}
|
||||
{{- if or .Values.slides.ingress.certManager.enabled .Values.slides.ingress.annotations }}
|
||||
annotations:
|
||||
{{- if .Values.slides.ingress.certManager.enabled }}
|
||||
cert-manager.io/cluster-issuer: {{ .Values.slides.ingress.certManager.clusterIssuer | quote }}
|
||||
{{- end }}
|
||||
{{- with .Values.slides.ingress.annotations }}
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
spec:
|
||||
{{- if .Values.slides.ingress.className }}
|
||||
ingressClassName: {{ .Values.slides.ingress.className }}
|
||||
{{- end }}
|
||||
{{- if $tlsOn }}
|
||||
tls:
|
||||
- hosts:
|
||||
{{- range .Values.slides.ingress.hosts }}
|
||||
- {{ .host | quote }}
|
||||
{{- end }}
|
||||
secretName: {{ .Values.slides.ingress.tls.secretName | default (printf "%s-tls" (include "talks-slides.fullname" .)) }}
|
||||
{{- end }}
|
||||
rules:
|
||||
{{- range .Values.slides.ingress.hosts }}
|
||||
- host: {{ .host | quote }}
|
||||
http:
|
||||
paths:
|
||||
{{- range .paths }}
|
||||
- path: {{ .path }}
|
||||
pathType: {{ .pathType }}
|
||||
backend:
|
||||
service:
|
||||
name: {{ include "talks-slides.fullname" $ }}
|
||||
port:
|
||||
number: {{ $.Values.slides.service.port }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
Reference in New Issue
Block a user