{{- if .Values.ingress.enabled }}
{{- range .Values.ingress.secrets }}
apiVersion: v1
kind: Secret
metadata:
  name: {{ .name }}
  labels:
    app: {{ template "prestashop.name" $ }}
    chart: {{ template "prestashop.chart" $ }}
    release: {{ $.Release.Name }}
    heritage: {{ $.Release.Service }}
type: kubernetes.io/tls
data:
  tls.crt: {{ .certificate | b64enc }}
  tls.key: {{ .key | b64enc }}
{{- end }}
{{- end }}
