Anyone have experience running two separate Docker containers instead of the secondsite method?

Wait. Did you clone Discourse twice? You want clone Discourse once and then have multiple yml files in the containers directory.

Maybe look at Use Nginx Proxy Manager to manage multiple sites with Discourse, though https://hub.docker.com/r/jwilder/nginx-proxy is the one that I’ve used. You just need to add some ENV variables to your YML to get it to connect up, but there are still a whole bunch of things that you have to understand to make it work.

Each site has its own hostname. That’s the point of all this, right?

I have the reverse proxy talk to port 80 on the container. Others prefer to use sockets. You should not expose any ports.

No. None of those files can be shared.

Each site needs a postgres database (can be on the same postgres server if you know how to do that).

Each site needs its own redis. They cannot share redis, which is one advantage of the multisite setup.

If you want to run two postgres’s, then just change the hostname, smtp, and volume paths and remove/comment out the ssl and letsencrypt templates. You can even use discourse-setup if you rename app.yml to, say, hostname.yml before you run ./discourse-setup again.

1 Like