Replies: 7 comments
-
Can anybody help, please? |
Beta Was this translation helpful? Give feedback.
-
I will post a video soon on that... but basically you can check the repo wordpress... it should be on folder/repo for each site, change settings in env file and service name in the docker-compose file. |
Beta Was this translation helpful? Give feedback.
-
@Elmit2015 As I understand it: How do I setup 2 web sites?
Yes. For a two-site setup, I have three folders each with docker-compose.yml. Two for the websites, one for nginx-proxy (a fork of this repository in case I make changes)
As I use three separate folders/repositories, the directory structure looks something like this in production:
Not a problem. In website1.com and website2.com, set the
So, in your website docker-compose, add the network and set it to external: version: "3"
services:
app:
image: nginx:latest
environment:
VIRTUAL_HOST: "website1.com"
networks:
- webproxy
networks:
webproxy:
external: true Hope that helps, as a disclaimer I'm still learning about the project so may have a few points wrong. |
Beta Was this translation helpful? Give feedback.
-
@cwilby I'm having some issues on making more than one website to work. If you got the time, could you kindly give me some insights? Thanks a lot! |
Beta Was this translation helpful? Give feedback.
-
@Darksoulsong sure, I’m traveling at the moment but can share more later. I have a solution running several websites on a single docker host using this repo: https://github.com/JrCs/docker-letsencrypt-nginx-proxy-companion |
Beta Was this translation helpful? Give feedback.
-
@cwilby this project uses the same companion you have mentioned just atuomate things for you, I mention that in the readme. |
Beta Was this translation helpful? Give feedback.
-
Why not use a discussion for such? Not an issue, could be closed again :) |
Beta Was this translation helpful? Give feedback.
-
I need some help to understand the entire system here.
I understand that the front-end is the proxy companion and behind are the the other web sites. As example is docker-wordpress-letsencrypt.
How do I setup 2 web sites?
Do I use a directory for each web site with a docker-compose.yml customized for each web site? That would make the .env clear for each site. Or do I use one docker-compose.yml for all web sites and add sections for each web site (services)?
What is the best directory structure for multiple web sites? I am thinking on backup, or moving to other hosts.
I have my web sites now running with nginx. These are web sites with different domain names, for which I do have different nginx config files. Some of the sites use authentication and some have a connection to a trading bot or chat bot, where I listen for incoming information.
How is the link between the proxy companion and the web site. I assume with:
networks: default: name: ${NETWORK}
Beta Was this translation helpful? Give feedback.
All reactions