-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.prod.yml
30 lines (28 loc) · 1.48 KB
/
docker-compose.prod.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
version: '3.9'
services:
tredtrix:
image: ghcr.io/jimmylevell/tredtrix/tredtrix:latest
networks:
- traefik-public
deploy:
replicas: 1
update_config:
parallelism: 1
delay: 10s
restart_policy:
condition: on-failure
labels:
- traefik.enable=true # enable traefik
- traefik.docker.network=traefik-public # put it in the same network as traefik
- traefik.constraint-label=traefik-public # assign the same label as traefik so it can be discovered
- traefik.http.routers.tredtrix.rule=Host(`tredtrix.app.levell.ch`) # listen to port 80 for request to APP_DOMAIN (use together with the line below)
- traefik.http.routers.tredtrix.entrypoints=http
- traefik.http.middlewares.tredtrix.redirectscheme.scheme=https # redirect traffic to https
- traefik.http.middlewares.tredtrix.redirectscheme.permanent=true # redirect traffic to https
- traefik.http.routers.tredtrix-secured.rule=Host(`tredtrix.app.levell.ch`) # listen to port 443 for request to APP_DOMAIN (use together with the line below)
- traefik.http.routers.tredtrix-secured.entrypoints=https
- traefik.http.routers.tredtrix-secured.tls.certresolver=le # use the Let's Encrypt certificate we set up earlier
- traefik.http.services.tredtrix-secured.loadbalancer.server.port=80 # ask Traefik to search for port service container
networks:
traefik-public:
external: true