{{- if .Values.ingress.enabled -}} apiVersion: extensions/v1beta1 kind: Ingress metadata: name: {{ template "tracing.fullname" . }} namespace: {{ .Release.Namespace }} labels: app: {{ .Values.provider }} chart: {{ template "tracing.chart" . }} heritage: {{ .Release.Service }} release: {{ .Release.Name }} annotations: {{- range $key, $value := .Values.ingress.annotations }} {{ $key }}: {{ $value | quote }} {{- end }} spec: rules: {{- if .Values.ingress.hosts }} {{- range $host := .Values.ingress.hosts }} - host: {{ $host }} http: paths: - path: {{ if $.Values.contextPath }} {{ $.Values.contextPath }} {{ else }} /{{ $.Values.provider }} {{ end }} backend: serviceName: tracing servicePort: 80 {{- end -}} {{- else }} - http: paths: - path: {{ if .Values.contextPath }} {{ .Values.contextPath }} {{ else }} /{{ .Values.provider }} {{ end }} backend: serviceName: tracing servicePort: 80 {{- end }} {{- if .Values.ingress.tls }} tls: {{ toYaml .Values.ingress.tls | indent 4 }} {{- end -}} {{- end -}}