---
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
  name: plex-server
  namespace: networking
  annotations:
    cert-manager.io/cluster-issuer: "letsencrypt-production"
    traefik.ingress.kubernetes.io/router.entrypoints: "websecure"
spec:
  rules:
    - host: "plex.${SECRET_OLD_DOMAIN}"
      http:
        paths:
          - backend:
              service:
                name: plex-server
                port:
                  number: 32400
            path: /
            pathType: Prefix
  tls:
    - hosts:
        - "plex.${SECRET_OLD_DOMAIN}"
      secretName: plex-server-cert
