apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
  name: myingress
  annotations:
    kubernetes.io/ingress.class: nginx
    nginx.ingress.kubernetes.io/use-regex: "true"
    nginx.ingress.kubernetes.io/rewrite-target: "/$2"
  labels:
    name: gateway
spec:
  defaultBackend:
    service:
      name: gateway-svc
      port:
        name: entrypoint
  rules:
    # host: <Host> #Placeholder. Dunno what to put. may be optional.
  - http:
      paths:
      - pathType: Prefix
        path: "/flashcard(/|$)(.*)"
        backend:
          service:
            name: flashcard-svc
            port: 
              name: fc-port
      - pathType: Prefix
        path: "/quiz(/|$)(.*)"
        backend:
          service:
            name: quiz-svc
            port: 
              name: quiz-port
