Hi there,
I've been using traefik to route to several subdomains and it all works swell.
I decided to add a wordpress + mysql dockers in same yml file.
I litteraly copied the traefik labels configuration from another docker and modified it to wordpress purpose, and I'm just getting a gateway timeout message.
I checked traefik logs, nothing.
The wordpress instance shows up well on its local network port, but not using subdomain.mydomain.org.
this config is exactly the same as for my other subdomains, and it shows up at localhost:8085
There is one thing that I thought could be the issue, since Traefik is already using port 80, is it a possibility that since wordpress uses 80 as internal port, and the loadbalancer is on that port that it screws it all up ?
multiple containers with the same port are no problem.
Are traefik and this wordpress container in the same docker network? I don't see any network configuration here.
Could be an idea to create an external docker network and use this network in all your containers providing services for traefik.
Hi @wollomatic ,
Thanks for the reply. I did check that, they are both in same internal network and in the same stack. And wordpress is in another network as well, specifically to communicate with its mysql container.
I don't see any obvious error in the config.
I guess you checked the dashboard and the connection between router/middleware/service is okay?
Did you set traefik's log level to debug?
Maybe it's worth to try it without authelia.
yes it's super weird.
I checked the dashboard for any errors or warnings, I checked that all connection went well.
I did also set traefik log to debug but I didn't spot anything special, no error message for that container.
I will try because "who knows" but Authelia seems to be working fine. I added an authelia policy for that website to bypass authelia 2FA, if I remove that policy it goes well to authelia, requests 2FA, and then and only then does it give me the error message.
I'll be posting the results of removing authelia entirely for this container later.
Hi,
So I tried removing authelia entirely but to no avail. I get gateway timeout systematically.
It's very confusing. The only thing I am thinking about is the loadbalancing port 80. If i change it to something else, it doesn't work. If I remove the line about loadblancer, I get an error in traefik saying the service blc@docker doesn't exist (because the service is now called blc-blc@docker.
Cheers for any help.
I found a way to change wordpress container internal port, and that way I now know for sure that the fact that its loadbalancer that was on port 80, doesn't get into conflict with traefik.
But the issue still remains. wordpress.mydomain.com is still in "Gateway Timeout"
I can't find any reason or clues that could help me figure out why.
Config is virtually the same as many other containers in the stack that all respond where requested with a subdomain.domain.org url.
I discovered that the wordpress container is exposing port 80.
I know that traefik is also busy with port 80.
Is that possible that this exposed port makes traefik unable to route to it due to the confusion ?
The 504 - Gateway Timeout error often occurs when the service is not accessible from Traefik.
In case of multiple networks, Traefik does know which one to use. You can have a look here.
NOTE: The label described in the linked answer is also available on a per-container basis.