---
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
  name: rest-hello
  annotations:
    nginx.ingress.kubernetes.io/use-regex: "true"
    nginx.ingress.kubernetes.io/rewrite-target: /$2
spec:
  ingressClassName: nginx
  rules:
    - http:
        paths:
          - path: /appl(/|$)(.*)
            pathType: Prefix
            backend:
              service:
                name: rest-hello
                port:
                  number: 80
