-
Notifications
You must be signed in to change notification settings - Fork 11
/
Copy pathdocker-compose-traefik.yml
47 lines (44 loc) · 1.66 KB
/
docker-compose-traefik.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
# Thanks to @[email protected] for contributing this
services:
traefik:
image: traefik:v2.5
volumes:
- acme:/acme/acme.json
- /var/run/docker.sock:/var/run/docker.sock
ports:
- "${HTTP:?}:80"
- "${HTTPS:?}:443"
command: >
--global.checknewversion=false
--global.sendanonymoususage=false
--entryPoints.web.address=:80
--entryPoints.websecure.address=:443
--certificatesresolvers.myresolver=true
--certificatesresolvers.myresolver.acme.email=${SSL_EMAIL:?}
--certificatesresolvers.myresolver.acme.storage=/acme/acme.json
--certificatesResolvers.myresolver.acme.tlsChallenge=true
--log=true
--log.level=DEBUG
--accesslog=true
--api.insecure=true
--api.dashboard=true
--providers.docker=true
--providers.docker.exposedByDefault=false
--providers.docker.defaultRule="Host(`{{ trimPrefix `/` .Name }}.docker.localhost`)"
--pilot.dashboard=false
--tracing=false
proxy:
image: unifiedpush/common-proxies
environment:
- UP_GATEWAY_MATRIX_ENABLE=true
restart: always
labels:
- "traefik.enable=true"
- "traefik.http.routers.commonproxies-tls.entrypoints=websecure"
- "traefik.http.routers.commonproxies-tls.tls=true"
- "traefik.http.routers.commonproxies-tls.tls.certresolver=myresolver"
- "traefik.http.routers.commonproxies-tls.rule=Host(`${LISTEN_DOMAIN:?}`) && PathPrefix(`/generic`, `/FCM`, `/_matrix`)"
- "traefik.http.routers.commonproxies-tls.service=commonproxies-tls-service"
- "traefik.http.services.commonproxies-tls-service.loadbalancer.server.port=5000"
volumes:
acme: