thirdparty-ops-docker-helm/charts/rstudio/templates/ingress.yaml

36 lines
947 B
YAML
Raw Normal View History

2018-11-06 06:42:18 +01:00
{{- if .Values.ingress.enabled }}
{{- range .Values.ingress.hosts }}
apiVersion: extensions/v1beta1
kind: Ingress
metadata:
name: "{{ $.Release.Name }}-ingress"
labels:
2018-11-06 17:19:54 +01:00
app: "{{ .Release.Name}}-{{ .Values.rstudio.service.name }}"
2018-11-06 06:42:18 +01:00
chart: "{{ $.Chart.Name }}-{{ $.Chart.Version }}"
release: "{{ $.Release.Name }}"
heritage: "{{ $.Release.Service }}"
annotations:
{{- if .tls }}
ingress.kubernetes.io/secure-backends: "true"
{{- end }}
{{- range $key, $value := .annotations }}
{{ $key }}: {{ $value | quote }}
{{- end }}
spec:
rules:
2018-11-06 06:58:18 +01:00
- host: {{ .name }}
2018-11-06 06:42:18 +01:00
http:
paths:
- path: {{ default "/" .path }}
backend:
2018-11-06 17:19:54 +01:00
serviceName: "{{ .Release.Name}}-{{ .Values.rstudio.service.name }}"
2018-11-06 06:42:18 +01:00
servicePort: {{ $.Values.rstudio.service.port }}
{{- if .tls }}
tls:
- hosts:
- {{ .name }}
secretName: {{ .tlsSecret }}
{{- end }}
---
{{- end }}
{{- end }}