examples update and multiple REVERSE_PROXY_* on single site

This commit is contained in:
bunkerity
2020-11-15 14:55:48 +01:00
parent 0f18e9c552
commit ed451877ae
29 changed files with 195 additions and 74 deletions

View File

@@ -12,43 +12,70 @@ services:
- /var/run/docker.sock:/var/run/docker.sock
- ./traefik/traefik.toml:/traefik.toml
- ./traefik/acme.json:/acme.json
networks:
- netwww1
- netwww2
mywww1:
image: bunkerity/bunkerized-nginx
restart: always
volumes:
- ./web1:/www
- ./web1:/www:ro
environment:
- SERVER_NAME=app1.website.com
- PROXY_REAL_IP=yes
- USE_CLIENT_CACHE=yes
- USE_GZIP=yes
- USE_BROTLI=yes
- REMOTE_PHP=myphp1
- REMOTE_PHP_PATH=/app
labels:
- 'traefik.enable=true'
- 'traefik.port=8080'
- 'traefik.frontend.rule=Host:app1.website.com' # replace with your domain
networks:
- netwww1
- netphp1
mywww2:
image: bunkerity/bunkerized-nginx
restart: always
volumes:
- ./web2:/www
- ./web2:/www:ro
environment:
- SERVER_NAME=app2.website.com
- PROXY_REAL_IP=yes
- USE_CLIENT_CACHE=yes
- USE_GZIP=yes
- USE_BROTLI=yes
- REMOTE_PHP=myphp2
- REMOTE_PHP_PATH=/app
labels:
- 'traefik.enable=true'
- 'traefik.port=8080'
- 'traefik.frontend.rule=Host:app2.website.com' # replace with your domain
networks:
- netwww2
- netphp2
myphp1:
image: php:fpm
restart: always
volumes:
- ./web1:/app
networks:
- netphp1
myphp2:
image: php:fpm
restart: always
volumes:
- ./web2:/app
networks:
- netphp2
networks:
netwww1:
netwww2:
netphp1:
netphp2: