-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.prod.yml
58 lines (56 loc) · 1.98 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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
services:
# production services
traefik:
image: traefik:v2.11.0
command:
- --api.insecure=true
- --api.dashboard=true
- --providers.docker=true
- --providers.docker.exposedbydefault=false
- --entrypoints.web.address=:8888
- --entrypoints.web.http.redirections.entrypoint.to=websecure
- --entrypoints.web.http.redirections.entrypoint.scheme=https
- --entrypoints.websecure.address=:443
- --certificatesresolvers.myresolver.acme.tlschallenge=true
- --certificatesresolvers.myresolver.acme.email=michael@leagueify.org
- --certificatesresolvers.myresolver.acme.storage=/letsencrypt/acme.json
labels:
- traefik.enable=true
- traefik.http.routers.traefik.rule=Host(`traefik.localhost`)
- traefik.http.routers.traefik.entrypoints=websecure
- traefik.http.routers.traefik.service=api@internal
- traefik.http.routers.traefik.tls=true
- traefik.http.routers.traefik.tls.certresolver=myresolver
ports:
- 80:8888
- 443:443
volumes:
- /var/run/docker.sock:/var/run/docker.sock:ro
- ./letsencrypt:/letsencrypt
restart: always
leagueify:
image: ghcr.io/leagueify/leagueify:latest
labels:
- traefik.enable=true
- traefik.http.routers.leagueify.rule=Host(`localhost`)
- traefik.http.routers.leagueify.entrypoints=websecure
- traefik.http.routers.leagueify.tls=true
- traefik.http.routers.leagueify.tls.certresolver=myresolver
- traefik.http.middlewares.leagueify.ratelimit.average=100
environment:
DB_CONN_STR: host=database user=leagueify-user password=leagueify-pass dbname=leagueify sslmode=disable
expose:
- 8888
restart: always
database:
container_name: database
image: postgres:16.2-alpine3.19
environment:
POSTGRES_USER: leagueify-user
POSTGRES_PASSWORD: leagueify-pass
POSTGRES_DB: leagueify
expose:
- 5432
volumes:
- database:/data/db
restart: always