-
-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathcompose.yml
111 lines (104 loc) · 2.38 KB
/
compose.yml
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
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
version: "3.9"
name: voilib
x-defaults: &defaults
logging:
driver: "json-file"
options:
max-file: 5
max-size: 10m
restart: unless-stopped
services:
backend:
<<: *defaults
image: voilib-backend:latest
build:
context: ../../backend
dockerfile: dockerfile
args:
INSTALL_DEV: true
depends_on:
redis:
condition: service_healthy
env_file:
- .env.dev
ports:
- ${VITE_API_PORT:-81}:80
command: uvicorn src.voilib.main:app --reload --host 0.0.0.0 --port 80
volumes:
- ../../backend/:/backend/
- ../../data/:/data/
healthcheck:
test: ["CMD", "curl", "-f", "0.0.0.0/app/version"]
interval: 6s
timeout: 10s
retries: 50
frontend:
<<: *defaults
image: voilib-ui:latest
depends_on:
backend:
condition: service_healthy
env_file:
- .env.dev
ports:
- ${VOILIB_FRONTEND_PORT:-80}:5173 # expose the port just internally, as we are using traefik
build:
context: ../../frontend
dockerfile: dockerfile.dev
volumes:
- ../../frontend/src:/frontend/src
- ../../frontend/public:/frontend/public
healthcheck:
test: ["CMD", "curl", "-f", "0.0.0.0:5173"]
interval: 6s
timeout: 10s
retries: 50
management:
<<: *defaults
image: voilib-backend:latest
env_file:
- .env.dev
build:
context: ../../backend
dockerfile: dockerfile
args:
INSTALL_DEV: true
ports:
- ${VOILIB_MANAGEMENT_PORT:-8501}:8501
command: streamlit run src/voilib/management/🏠-Home.py
volumes:
- ../../backend/:/backend/
- ../../data/:/data/
redis:
<<: *defaults
image: redis:7.0.4-alpine
hostname: ${REDIS_HOST}
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 1s
timeout: 3s
retries: 30
worker:
<<: *defaults
image: voilib-backend:latest
depends_on:
redis:
condition: service_healthy
env_file:
- .env.dev
build:
context: ../../backend
dockerfile: dockerfile
args:
INSTALL_DEV: true
command: python src/voilib/worker.py
volumes:
- ../../backend/:/backend/
- ../../data/:/data/
qdrant:
<<: *defaults
image: qdrant/qdrant:v1.1.3
expose:
- 6333
volumes:
- ../../data/qdrant/:/qdrant/storage