-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
69 lines (65 loc) · 1.65 KB
/
Copy pathdocker-compose.yml
File metadata and controls
69 lines (65 loc) · 1.65 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
services:
postgres:
image: postgres:17-alpine
environment:
POSTGRES_USER: spillio
POSTGRES_PASSWORD: spillio
POSTGRES_DB: spillio
ports:
- "5432:5432"
volumes:
- spillio-postgres:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U spillio -d spillio"]
interval: 5s
timeout: 5s
retries: 10
api:
profiles: ["app"]
build:
context: .
dockerfile: services/api/Dockerfile
environment:
DATABASE_URL: postgres://spillio:spillio@postgres:5432/spillio
SPILLIO_API_ADDR: 0.0.0.0:4000
SPILLIO_AUTH_MODE: local
SPILLIO_KLIPY_API_KEY: ${SPILLIO_KLIPY_API_KEY:-}
RUST_LOG: info
depends_on:
migrate:
condition: service_completed_successfully
ports:
- "4000:4000"
healthcheck:
test: ["CMD-SHELL", "curl -fsS http://127.0.0.1:4000/health >/dev/null"]
interval: 10s
timeout: 5s
retries: 5
migrate:
profiles: ["app"]
build:
context: .
dockerfile: services/api/Dockerfile
command: ["spillio-api", "migrate"]
environment:
DATABASE_URL: postgres://spillio:spillio@postgres:5432/spillio
depends_on:
postgres:
condition: service_healthy
web:
profiles: ["app"]
build:
context: .
dockerfile: apps/web/Dockerfile
environment:
SPILLIO_API_URL: http://api:4000
SPILLIO_BROWSER_API_URL: http://127.0.0.1:4000
NEXT_PUBLIC_SPILLIO_API_URL: http://127.0.0.1:4000
SPILLIO_AUTH_MODE: local
depends_on:
api:
condition: service_healthy
ports:
- "3000:3000"
volumes:
spillio-postgres: