-
Notifications
You must be signed in to change notification settings - Fork 2
/
docker-compose.yaml
47 lines (47 loc) · 1.69 KB
/
docker-compose.yaml
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
services:
web:
image: ghcr.io/gafirst/match-uploader:latest
ports:
- 80:8080 # host:container. Change `host` to change the port Match Uploader is accessible on from the host machine
env_file:
- ./server/env/production.env
volumes: &common_volumes
- ./server/settings:/home/node/app/server/settings
- ./server/env:/home/node/app/server/env
- ./server/videos:/home/node/app/server/videos # Adjust the first part of this value (e.g., `./server/videos`) to change the videos directory Match Uploader looks in to find videos to upload
healthcheck:
test: ["CMD", "curl", "-f", "-LI", "http://localhost:8080"] # Based on https://stackoverflow.com/a/57433225
interval: 2s
timeout: 5s
retries: 10
depends_on:
db:
condition: service_healthy # https://stackoverflow.com/a/55835081
worker:
image: ghcr.io/gafirst/match-uploader:latest
command: yarn start:worker
volumes: *common_volumes
env_file:
- ./server/env/production.env
depends_on:
db:
condition: service_healthy # https://stackoverflow.com/a/55835081
web:
condition: service_healthy
db:
image: postgres:16-bookworm
shm_size: '256mb' # https://github.com/docker-library/docs/blob/d94174bea5222aa95674ac156b710648a186afb8/postgres/README.md#caveats#caveats
env_file:
- ./server/env/production.env
environment:
TZ: America/New_York
PGTZ: America/New_York
volumes:
- db_data:/var/lib/postgresql/data
healthcheck: # https://stackoverflow.com/a/55835081
test: [ "CMD-SHELL", "pg_isready -U match_uploader" ]
interval: 2s
timeout: 5s
retries: 10
volumes:
db_data: