apiVersion: extensions/v1beta1 kind: Ingress metadata: annotations: kubernetes.io/ingress.class: nginx nginx.ingress.kubernetes.io/auth-response-headers: X-User-Id, X-User-Name, X-User-Email, X-User-Username, X-Security-Principal nginx.ingress.kubernetes.io/auth-signin: http://example.com/auth/signIn nginx.ingress.kubernetes.io/auth-snippet: | proxy_set_header X-Check-URL $scheme://$http_host$request_uri; nginx.ingress.kubernetes.io/auth-url: http://service-authenticationagent.example.svc.cluster.local/auth/check creationTimestamp: null generation: 1 labels: app: index name: index spec: rules: - host: example.com http: paths: - backend: serviceName: service-landing-page servicePort: 80 path: / --- apiVersion: extensions/v1beta1 kind: Ingress metadata: annotations: kubernetes.io/ingress.class: nginx nginx.ingress.kubernetes.io/auth-response-headers: X-User-Id, X-User-Name, X-User-Email, X-User-Username, X-Security-Principal nginx.ingress.kubernetes.io/auth-signin: http://example.com/auth/signIn nginx.ingress.kubernetes.io/auth-snippet: | proxy_set_header X-Check-URL $scheme://$http_host$request_uri; nginx.ingress.kubernetes.io/auth-url: http://service-authenticationagent.example.svc.cluster.local/auth/check nginx.ingress.kubernetes.io/rewrite-target: /foo-example/$2 labels: app: foo-example name: foo-example spec: rules: - host: example.com http: paths: - backend: serviceName: service-foo servicePort: 80 path: /foo-example(/|$)(.*) - host: foo.example.com http: paths: - backend: serviceName: service-foo servicePort: 80 path: /foo-example(/|$)(.*) --- apiVersion: extensions/v1beta1 kind: Ingress metadata: annotations: kubernetes.io/ingress.class: nginx nginx.ingress.kubernetes.io/rewrite-target: /api/v1$1 labels: app: foo-example-public-api name: foo-example-public-api namespace: sasa spec: rules: - host: foo.example.com http: paths: - backend: serviceName: service-foo servicePort: 80 path: /foo-example-1(/.*|$)