-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcompose.yaml
More file actions
79 lines (75 loc) · 2.15 KB
/
Copy pathcompose.yaml
File metadata and controls
79 lines (75 loc) · 2.15 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
73
74
75
76
77
78
79
services:
mongodb:
image: mongodb/mongodb-atlas-local
hostname: mongodb # <-- 1. ADD THIS: Fixes the replica set breaking on restart.
environment:
- MONGODB_INITDB_ROOT_USERNAME=${DB_USER}
- MONGODB_INITDB_ROOT_PASSWORD=${DB_PASSWORD}
- GLIBC_TUNABLES=glibc.pthread.rseq=0 # <-- 2. ADD THIS: Fixes the performance warning.
ports:
- 27017:27017
volumes:
# - ./init:/docker-entrypoint-initdb.d
- db:/data/db
- configdb:/data/configdb
- mongot:/data/mongot
healthcheck:
test: ["CMD", "mongosh", "--eval", "db.adminCommand('ping')"]
interval: 10s
timeout: 5s
retries: 5
start_period: 20s
backend:
build: ./backend/
restart: on-failure
environment:
- DB_URL=${DB_URL}
- JWT_SECRET=${JWT_SECRET}
- R2_ACCOUNT_ID=${R2_ACCOUNT_ID}
- R2_ACCESS_KEY=${R2_ACCESS_KEY}
- R2_SECRET_KEY=${R2_SECRET_KEY}
- R2_LISTINGS_ENDPOINT=${R2_LISTINGS_ENDPOINT}
- R2_BUCKET_RULEBOOKS=${R2_BUCKET_RULEBOOKS}
- R2_BUCKET_PROFILES=${R2_BUCKET_PROFILES}
- R2_BUCKET_LISTINGS=${R2_BUCKET_LISTINGS}
- R2_DEV_URL=${R2_DEV_URL}
- R2_PROD_URL=${R2_PROD_URL}
ports:
- 8080:8080
depends_on:
mongodb:
condition: service_healthy
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8080/api/auth/hello"]
interval: 30s
timeout: 10s
retries: 3
start_period: 20s
ai-gateway:
build: ./ai/
restart: on-failure
environment:
- DB_URL=${DB_URL}
- DB_NAME=${DB_NAME}
- JWT_SECRET=${JWT_SECRET}
- R2_ACCOUNT_ID=${R2_ACCOUNT_ID}
- R2_BUCKET_RULEBOOKS=${R2_BUCKET_RULEBOOKS}
- R2_ACCESS_KEY=${R2_ACCESS_KEY}
- R2_SECRET_KEY=${R2_SECRET_KEY}
- R2_BUCKET_LISTINGS=${R2_BUCKET_LISTINGS}
- R2_LISTINGS_ENDPOINT=${R2_LISTINGS_ENDPOINT}
ports:
- 8000:8000
depends_on:
mongodb:
condition: service_healthy
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8000/health"]
interval: 30s
timeout: 10s
retries: 3
start_period: 20s
volumes:
db:
configdb:
mongot: