Traefik v2 disable https access for http endpoint

I try to make a https request over the http endpoint, and it is working with a self-signed cert with traefik. Is there any method to disable the https support on the http endpoint?

$ curl https://127.0.0.1:80

curl: (60) Issuer certificate is invalid.
More details here: http://curl.haxx.se/docs/sslcerts.html

$ curl http://127.0.0.1:80
404 page not found

1 Like

Hello,

in the v2, the TLS configuration in on the router https://docs.traefik.io/v2.0/routing/routers/#tls

So you have to set only the HTTPS entrypoint on the router: https://docs.traefik.io/v2.0/routing/routers/#entrypoints

So it is possible to submit a https request to port 80, and traefik tries to answer this request (e.g. a 404 HTTP Response), instead, I would expect, that traefik answers with an Error (SSL_connect: SSL_ERROR_SYSCALL).

How can I configure traefik, so that only http (and not https) is possible?

1 Like

@ldez this does not help, because I want to disable https over port 80 - and do not want to enable TLS

1 Like