First of all, only bid on this if you having good experience with Docker for windows, wsl2, docker compose.
So the problem I having is this:
I need to have up to 4 containers running at the same time. All theese needs to listen to port 80 and 443 becuase they will be running on a subdomain that is pointed to [login to view URL] in the dns.
And the containers will need to run WordPress and also for an example container 1 will need to access container 2 database thru custom pdo connection. And there I connect to the other database thru, dbname, dbpass, dbuser and dbhost (ip adress and port)
I have started with an [login to view URL] file for the wordpress container, and also an [login to view URL] file for an nginx proxy container. But then I got stucked, running one container with the proxy is working fine. but two containers does not work at all. They gets in conflict with each other.
So the end result I would like to get:
- Two [login to view URL] files that are configured for WordPress container with mysql or mariadb, also mailhog would me a plus.
- An instruction how I can get it to work.
I have added the files what I have so far.