mirror of
https://github.com/phfroidmont/self-hosting.git
synced 2025-12-25 05:36:59 +01:00
Replace nginx reverse proxy by traefik
This commit is contained in:
parent
fd30d66ffb
commit
cfaa48e02a
30 changed files with 271 additions and 161 deletions
|
|
@ -3,7 +3,6 @@ services:
|
|||
db:
|
||||
image: postgres:9.6
|
||||
restart: always
|
||||
# Adding 127.0.0.1 ensures the port isn't exposed ON the host
|
||||
ports:
|
||||
- "127.0.0.1:5432:5432"
|
||||
volumes:
|
||||
|
|
@ -22,10 +21,13 @@ services:
|
|||
- "127.0.0.1:8008:8008"
|
||||
- "8448:8448"
|
||||
- "3478:3478"
|
||||
environment:
|
||||
- VIRTUAL_HOST=matrix.banditlair.com
|
||||
- VIRTUAL_NETWORK=nginx-proxy
|
||||
- VIRTUAL_PORT=8008
|
||||
labels:
|
||||
- "traefik.backend=synapse"
|
||||
- "traefik.docker.network=web"
|
||||
- "traefik.frontend.rule=Host:matrix.banditlair.com"
|
||||
- "traefik.enable=true"
|
||||
- "traefik.port=8008"
|
||||
- "traefik.default.protocol=http"
|
||||
volumes:
|
||||
- /var/lib/matrix/media_store:/data/media_store
|
||||
- /var/log/synapse:/data/log
|
||||
|
|
@ -33,13 +35,13 @@ services:
|
|||
- /etc/localtime:/etc/localtime:ro
|
||||
networks:
|
||||
- matrix
|
||||
- proxy-tier
|
||||
- web
|
||||
restart: always
|
||||
|
||||
networks:
|
||||
matrix:
|
||||
external:
|
||||
name: matrix-network
|
||||
proxy-tier:
|
||||
web:
|
||||
external:
|
||||
name: nginx-proxy
|
||||
name: web
|
||||
|
|
|
|||
|
|
@ -1,2 +1,2 @@
|
|||
dependencies:
|
||||
- nginx-proxy-docker
|
||||
- traefik-proxy-docker
|
||||
Loading…
Add table
Add a link
Reference in a new issue