-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
72 lines (71 loc) · 2.26 KB
/
docker-compose.yml
File metadata and controls
72 lines (71 loc) · 2.26 KB
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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
services:
postgres:
image: postgres:17-alpine
environment:
POSTGRES_USER: ${POSTGRES_USER}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
POSTGRES_DB: ${POSTGRES_DB}
ports:
- 127.0.0.1:5440:5432
volumes:
- postgres_data:/var/lib/postgresql/data/
healthcheck:
test: ["CMD-SHELL", "pg_isready -U \"$${POSTGRES_USER}\" -d \"$${POSTGRES_DB}\""]
interval: 5s
timeout: 5s
retries: 12
jamcore:
build:
context: .
dockerfile: Dockerfile
target: ${DOCKER_TARGET:-production}
init: true
restart: unless-stopped
stop_grace_period: 30s
cap_drop:
- ALL
security_opt:
- no-new-privileges:true
environment:
NODE_ENV: ${NODE_ENV:-development}
PORT: ${PORT:-3005}
CLIENT_ORIGIN: ${CLIENT_ORIGIN:-http://localhost:3000}
FEDERATION_ORIGIN: ${FEDERATION_ORIGIN:-http://localhost:3005}
FRONT_DEV_PORT: ${FRONT_DEV_PORT:-3000}
RUNTIME_ROLE: ${RUNTIME_ROLE:-all}
CACHE_PROVIDER: ${CACHE_PROVIDER:-memory}
RATE_LIMIT_PROVIDER: ${RATE_LIMIT_PROVIDER:-memory}
REDIS_URL: ${REDIS_URL:-}
TOKEN_SECRET: ${TOKEN_SECRET:-}
SERVICE_API_KEYS: ${SERVICE_API_KEYS:-}
TWITCH_CLIENT_ID: ${TWITCH_CLIENT_ID:-}
TWITCH_CLIENT_SECRET: ${TWITCH_CLIENT_SECRET:-}
APP_CONFIG_PATH: ${APP_CONFIG_PATH:-}
DISCORD_QUILT_WEBHOOK_URL: ${DISCORD_QUILT_WEBHOOK_URL:-}
R2_ENDPOINT: ${R2_ENDPOINT:-}
R2_BUCKET_NAME: ${R2_BUCKET_NAME:-}
AWS_ACCESS_KEY_ID: ${AWS_ACCESS_KEY_ID:-}
AWS_SECRET_ACCESS_KEY: ${AWS_SECRET_ACCESS_KEY:-}
DATABASE_URL: "postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@postgres:5432/${POSTGRES_DB}"
ports:
- 127.0.0.1:3005:3005
depends_on:
postgres:
condition: service_healthy
volumes:
- jamcore_runtime:/usr/src/app/.jamcore
- jamcore_logs:/usr/src/app/logs
- jamcore_images:/usr/src/app/public/images
entrypoint: >
sh -c "npx prisma migrate deploy && npm start"
healthcheck:
test: ["CMD-SHELL", "wget -q -O- http://127.0.0.1:$${PORT:-3005}/healthz >/dev/null 2>&1"]
interval: 10s
timeout: 5s
retries: 12
start_period: 20s
volumes:
postgres_data:
jamcore_runtime:
jamcore_logs:
jamcore_images: