Skip to content
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

nginx controller return error due to invalid pathType Prefix #139

Open
natthan-pigoux opened this issue Feb 6, 2025 · 2 comments
Open

Comments

@natthan-pigoux
Copy link

Here is a example of a minimal-ingress.yaml:

apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
  name: minimal-ingress
  annotations:
    nginx.ingress.kubernetes.io/rewrite-target: /
spec:
  ingressClassName: nginx
  rules:
  - host: nginx-example.zeuthen.desy.de
    http:
      paths:
      - path: /.well-known
        pathType: Prefix
        backend:
          service:
            name: test
            port:
              number: 80

When deploying it using kubectl apply -f minimal-ingress.yaml:

W0204 11:30:55.815720   50364 warnings.go:70] path /.well-known cannot be used with pathType Prefix
Error: INSTALLATION FAILED: failed to create resource: admission webhook "validate.nginx.ingress.kubernetes.io" denied the request: ingress contains invalid paths: path /.well-known cannot be used with pathType Prefix
@chaen
Copy link
Contributor

chaen commented Feb 12, 2025

I think this is your solution no ?
#122

@natthan-pigoux
Copy link
Author

I think this is your solution no ? #122

In out side, we changed the nginx controller configuration by setting: set strict-validate-path-type: "false" for nginx
And it fixed the error.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants