Hello Colleagues,
My issue:
I have configured:
- An nginx–ingress controller with the “nginx-ingress” ingressclass
- A ClusterIssuer with an http01 solver with the “nginx-ingress” ingressclass
- A VirtualServer with “spec.tls.redirect.enable: true” using the “nginx-ingress” ingressclass.
It seems that the redirect on the VirtualServer level prevents Lets Encrypt’s challenge to reach the virtual server’s “/.well-known/acme-challenge” endpoint because the TLS certificate does not yet exist at the moment (after the VirtualServer has been just created). So the certificate request process is stuck forever.
Solutions I’ve tried:
I have tried changing “spec.tls.redirect.enable” to false temporarily and after that the ClusterIssuer was able to get a certificate, and I changed the value back to true. However this variant is not suitable for production and will probably break if the certificate expires.
What I am looking for:
I would like to find a standard solution for all my virtualservers, or better on the controller level, so that the requests to “/.well-known/acme-challenge” were not redirected (if I have correctly identified the root cause of course).
Using the dns solver is out of the question currently, sorry.
Version of NIC and/or NGINX:
nginx-stable/nginx-ingress chart v2.4.4
Deployment environment:
K3s cluster, the nginx-ingress controller is using host networking.