Repository navigation
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
69 lines (66 loc) · 1.63 KB
/
Copy pathdocker-compose.yml
File metadata and controls
69 lines (66 loc) · 1.63 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:
embeddings:
build: ./services/embeddings
container_name: axf_embeddings
restart: unless-stopped
ports:
- "5000:5000"
healthcheck:
test: ["CMD", "python", "-c", "import urllib.request; urllib.request.urlopen('http://localhost:5000/health', timeout=3)"]
interval: 10s
timeout: 5s
retries: 10
start_period: 60s
postgres:
image: ankane/pgvector:latest
container_name: axf_postgres
restart: unless-stopped
environment:
POSTGRES_USER: axf_user
POSTGRES_PASSWORD: axf_pass
POSTGRES_DB: axf_db
ports:
- "5432:5432"
healthcheck:
test: ["CMD-SHELL", "pg_isready -U axf_user -d axf_db"]
interval: 5s
timeout: 5s
retries: 5
api:
build: ./services/api
image: alice-x-forest-api:latest
container_name: axf_api
restart: unless-stopped
command: ["npx", "tsx", "src/server.ts"]
volumes:
- ./services/api:/app
- /app/node_modules
depends_on:
postgres:
condition: service_healthy
redis:
condition: service_healthy
embeddings:
condition: service_healthy
environment:
DB_HOST: postgres
EMBEDDINGS_URL: http://embeddings:5000
DB_USER: axf_user
DB_PASSWORD: axf_pass
DB_NAME: axf_db
REDIS_HOST: redis
REDIS_PORT: 6379
ports:
- "3000:3000"
redis:
image: redis/redis-stack:latest
container_name: axf_redis
restart: unless-stopped
ports:
- "6379:6379"
- "8001:8001"
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 5s
timeout: 5s
retries: 5