{{- if .Values.ingress.enabled }}
apiVersion: extensions/v1beta1
kind: Ingress
metadata:
{{- if .Values.ingress.annotations }}
  annotations:
{{ toYaml .Values.ingress.annotations | indent 4 }}
{{- end }}
  name: {{ template "spinnaker.fullname" . }}
  labels:
{{ include "spinnaker.standard-labels" . | indent 4 }}
spec:
  rules:
  - host: {{ .Values.ingress.host | quote }}
    http:
      paths:
      - path: /
        backend:
          serviceName: spin-deck
          servicePort: 9000
{{- if .Values.ingress.tls }}
  tls:
{{ toYaml .Values.ingress.tls | indent 4 }}
{{- end -}}
{{- end }}
