-
Notifications
You must be signed in to change notification settings - Fork 8.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Wrong validation for permanent-redirect and temporal-redirect annotation values #12709
Comments
This issue is currently awaiting triage. If Ingress contributors determines this is a relevant issue, they will accept it by applying the The Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
I can notice the same behaviour when performing the minor update. Ingress objects using the annotation as such will break and get rejected by the controller: apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: my-domain-redirect
namespace: dev
annotations:
cert-manager.io/cluster-issuer: "letsencrypt-prod-http"
kubernetes.io/ingress.class: "nginx"
nginx.ingress.kubernetes.io/permanent-redirect: "https://my.new.domain$request_uri"
spec:
ingressClassName: nginx
rules:
- host: my.domain
- host: www.my.domain
tls:
- hosts:
- my.domain
- www.my.domain
secretName: my-domain-tls
Removing the |
Can confirm, updating from
|
Just to add on, auth-sign in validation appears broken when updating from
EDIT: |
Hi everyone,
I think in this file there is a wrong validator for the values of permanent-redirect and temporal-redirect annotation used.
Reasoning: It should be possible to use variables like "$request_uri" for redirecting to the same path as in the original request for example, but this is blocked by the validation because the $ is not allowed.
If I use a configuration-snippet with the following content, it works fine:
So for me it looks like if
URLWithNginxVariableRegex
should be the correct Regex to be used at this point.The text was updated successfully, but these errors were encountered: