Hi, I have a very strange behaviour :
I have to docker-compose.yml files wich exposes services through labels. One has an https passthrough, the other has an SSL cert configured with the dynconf file provider in a watched directory.
Here the confs:
- Mailu config
labels:
- "traefik.enable=true"
- "traefik.docker.network=publicweb"
- "traefik.http.routers.mailuhttp.rule=Host(`mx.leo-flaventin.com`) || Host(`mailu.leo-flaventin.com`) || Host(`autoconfig.mx.leo-flaventin.com`) || Host(`autoconfig.mailu.leo-flaventin.com`) || Host(`mta-sts.leo-flaventin.com`) || Host(`mta-sts.mx.leo-flaventin.com`) || Host(`mta-sts.mailu.leo-flaventin.com
`) || Host(`autoconfig.leo-flaventin.com`) || Path(`/.well-known/acme-challenge/`)"
- "traefik.http.routers.mailuhttp.entrypoints=web"
- "traefik.http.services.mailuhttp.loadbalancer.server.port=80"
- "traefik.tcp.routers.mailuhttps.rule=HostSNI(`mx.leo-flaventin.com`) || HostSNI(`mailu.leo-flaventin.com`) || HostSNI(`mail.leo-flaventin.com`) || HostSNI(`autoconfig.mx.leo-flaventin.com`) || HostSNI(`autoconfig.mailu.leo-flaventin.com`) || HostSNI(`autoconfig.mail.leo-flaventin.com`) || HostSNI(`mta-sts.
leo-flaventin.com`) || HostSNI(`mta-sts.mail.leo-flaventin.com`) || HostSNI(`mta-sts.mx.leo-flaventin.com`) || HostSNI(`mta-sts.mailu.leo-flaventin.com`) || HostSNI(`autoconfig.leo-flaventin.com`)"
- "traefik.tcp.routers.mailuhttps.entrypoints=websecure"
- "traefik.tcp.routers.mailuhttps.tls.passthrough=true"
- "traefik.tcp.routers.mailuhttps.service=mailuhttps"
- "traefik.tcp.services.mailuhttps.loadbalancer.server.port=443"
- "traefik.tcp.services.mailuhttps.loadbalancer.proxyProtocol.version=2"
- Mattermost config:
labels:
- "traefik.enable=true"
- "traefik.docker.network=publicweb"
- "traefik.http.routers.mattermost-http.entrypoints=web"
- "traefik.http.routers.mattermost-http.rule=Host(`mattermost.dev1.leo-flaventin.com`) || Host(`mattermost.leo-flaventin.com`)"
- "traefik.http.routers.mattermost-http.middlewares=mattermost-https"
- "traefik.http.middlewares.mattermost-https.redirectscheme.scheme=https"
- "traefik.http.routers.mattermost.entrypoints=websecure"
- "traefik.http.routers.mattermost.rule=Host(`mattermost.dev1.leo-flaventin.com`) || Host(`mattermost.leo-flaventin.com`)"
- "traefik.http.routers.mattermost.tls=true"
- "traefik.http.services.mattermost.loadbalancer.server.port=8065"
Here are some reproductible (at least on my host...) scenarios and how it behave depending on the order container are started:
- traefik > mailu > mattermost:
- traefik routes mattermost.dev1.leo-flaventin.com to mailu (instead of mattermost). mailu.dev1.leo-flaventin.com is correctly routed.
- traefik > mattermost
- traefik routes correctly to mattermost
- traefik > mattermost > mailu
- mattermsot is correctly routed, but mailu returns a 404
What is even weirder, is that in the dashboard, everything reported is as expected...
These behaviours seems strange enough to be a feature, should I file a bug or is it something wrong with my config ?