Hi,
I have an application that serves arbitrary subdomains. So everything at *.my.domain
should be passed on to this application.
I managed to do that using the following labels. I am using a DNS based certificate provider to request a wildcard certificate.
labels:
- "traefik.enable=true"
- "traefik.http.routers.mydomain.rule=HostRegexp(`.+.my.domain`)"
- "traefik.http.routers.mydomain.tls.certresolver=gandi"
- "traefik.http.routers.mydomain.tls.domains[0].main=*.my.domain"
- "traefik.http.routers.mydomain.tls.domains[0].sans=my.domain"
- "traefik.http.services.mydomain.loadbalancer.server.port=8080"
The above setup works fine, but I am getting the following warning in my traefik log:
WRN No domain found in rule HostRegexp(`.+.my.domain`), the TLS options applied for this router will depend on the SNI of each request entryPointName=web routerName=mydomain@docker
I am not sure I understand the issue this is reporting. Because traefik should serve the same wildcard certificate for all requests on this top level domain.
Is there a better way to configure my setup? Please note that this is not the only domain proxied through traefik - others are using a more conventional setup without any wildcard certs involved.