forked from binderjoe/phi-rag
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
43 lines (43 loc) · 1.37 KB
/
docker-compose.yml
File metadata and controls
43 lines (43 loc) · 1.37 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
version: "3.8"
services:
load:
build:
context: ./src
dockerfile: load/Dockerfile
env_file:
- .env
volumes:
- ./.data:/.data
- ./src/files:/files
environment:
- PYTHONUNBUFFERED=1
- DEBUG_WAIT_TIME=30 # Waits for 30 seconds before starting execution
- FORCE_LOAD=${FORCE_LOAD:-false}
- DEBUG_MODE=${DEBUG_MODE:-0} # Add this line for load service as well
command: /bin/sh -c "[ '${DEBUG_MODE:-0}' = '1' ] && exec python -m debugpy --listen 0.0.0.0:5679 --wait-for-client -m load.load.load || exec python -m load.load.load" # Adjust for debug mode
ports:
- "5679:5679" # debugpy port for load service, different from the one used by API
api:
build:
context: ./src
dockerfile: api/Dockerfile
ports:
- "3100:3100"
- "5678:5678" # debugpy port for API
env_file:
- .env
command: /bin/sh -c "[ '${DEBUG_MODE:-0}' = '1' ] && exec python -m debugpy --listen 0.0.0.0:5678 --wait-for-client -m uvicorn api.api.app:app --host 0.0.0.0 --port 3100 --proxy-headers || exec uvicorn api.api.app:app --host 0.0.0.0 --port 3100 --proxy-headers"
volumes:
- ./src/:/code/
- ./.data:/.data
depends_on:
- load
environment:
- PYTHONUNBUFFERED=1
web:
build:
context: ./src/web
ports:
- "3000:3000"
depends_on:
- api