k8s-pages/helm-chart/templates/ingress.yaml
2025-03-03 08:11:03 -06:00

27 lines
653 B
YAML

apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: nginx-reverse-proxy-ingress
namespace: {{ .Values.namespace }}
annotations:
cert-manager.io/cluster-issuer: letsencrypt-prod
spec:
rules:
{{- range .Values.sites }}
{{- if .apex }}
- host: {{ .host }}
{{- else if .subdomain }}
- host: {{ .subdomain }}.{{ .host }}
{{- else }}
- host: {{ .name }}.{{ .host }}
{{ end }}
http:
paths:
- path: /
pathType: Prefix
backend:
service:
name: nginx-reverse-proxy
port:
number: 80
{{- end }}