---
apiVersion: gateway.networking.k8s.io/v1
kind: HTTPRoute
metadata:
  name: authentik-ldap-dns
  namespace: authentik
  annotations:
    external-dns.alpha.kubernetes.io/hostname: ldap.k8s.syd1.au.unkin.net,ldap.main.unkin.net
    external-dns.alpha.kubernetes.io/target: 198.18.200.4
spec:
  hostnames:
    - ldap.k8s.syd1.au.unkin.net
    - ldap.main.unkin.net
  parentRefs:
    - group: gateway.networking.k8s.io
      kind: Gateway
      name: authentik-ldap
      sectionName: http-dns
    - group: gateway.networking.k8s.io
      kind: Gateway
      name: authentik-ldap
      sectionName: http-dns-main
  rules:
    - filters:
        - type: RequestRedirect
          requestRedirect:
            scheme: https
            statusCode: 301
      matches:
        - path:
            type: PathPrefix
            value: /
