-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
56 lines (53 loc) · 1.62 KB
/
Copy pathdocker-compose.yml
File metadata and controls
56 lines (53 loc) · 1.62 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
services:
postgres:
image: postgres:17
# Uncomment to access DB from outside Docker (for seeding/simulator)
# ports:
# - "5432:5432"
environment:
POSTGRES_USER: openmarket
POSTGRES_PASSWORD: ${DB_PASSWORD:-openmarket}
POSTGRES_DB: openmarket
volumes:
- pgdata:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U openmarket"]
interval: 5s
timeout: 3s
retries: 5
server:
build:
context: .
dockerfile: packages/server/Dockerfile
ports:
- "${API_PORT:-3000}:3000"
environment:
DATABASE_URL: postgresql://openmarket:${DB_PASSWORD:-openmarket}@postgres:5432/openmarket
API_PORT: 3000
PUBLIC_API_URL: ${PUBLIC_API_URL:-http://localhost:3000}
BETTER_AUTH_SECRET: ${BETTER_AUTH_SECRET:-openmarket-dev-secret-change-me}
BETTER_AUTH_URL: ${PUBLIC_API_URL:-http://localhost:3000}
DISCORD_CLIENT_ID: ${DISCORD_CLIENT_ID:-}
DISCORD_CLIENT_SECRET: ${DISCORD_CLIENT_SECRET:-}
CORS_ORIGINS: ${CORS_ORIGINS:-http://localhost:3001,http://localhost:5173,http://localhost:4173}
volumes:
- uploads:/app/packages/server/uploads
depends_on:
postgres:
condition: service_healthy
frontend:
build:
context: .
dockerfile: packages/frontend/Dockerfile
args:
PUBLIC_API_URL: ${PUBLIC_API_URL:-http://localhost:3000}
ports:
- "${FRONTEND_PORT:-3001}:3000"
environment:
PUBLIC_API_URL: ${PUBLIC_API_URL:-http://localhost:3000}
API_URL: http://server:3000
depends_on:
- server
volumes:
pgdata:
uploads: