-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
53 lines (50 loc) · 1.48 KB
/
Copy pathdocker-compose.yml
File metadata and controls
53 lines (50 loc) · 1.48 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
services:
# Omit or stop this service if you use Chroma Cloud (CHROMA_API_KEY in .env).
chromadb:
image: chromadb/chroma:1.0.21
container_name: notescanner-chromadb
ports:
- "8100:8000"
volumes:
# Chroma 1.x stores its data in /data inside the container.
- chroma_data:/data
backend:
build: .
container_name: notescanner-backend
depends_on:
- chromadb
env_file:
- .env
environment:
- CHROMA_HOST=chromadb
- CHROMA_PORT=8000
- PORT=8000
ports:
- "8000:8000"
# One worker: the chat-upload cache, request limits and per-user locks live in process memory.
command: ["uvicorn", "backend.api:app", "--host", "0.0.0.0", "--port", "8000", "--workers", "1"]
healthcheck:
test: ["CMD", "python", "-c", "import urllib.request; urllib.request.urlopen('http://127.0.0.1:8000/health', timeout=4)"]
interval: 30s
timeout: 5s
start_period: 60s
retries: 3
frontend:
build:
context: ./frontend/my-app
dockerfile: Dockerfile
container_name: notescanner-frontend
depends_on:
- backend
environment:
- VITE_API_URL=http://localhost:8000
ports:
- "5173:5173"
volumes:
- ./frontend/my-app/src:/app/src
- ./frontend/my-app/public:/app/public
- ./frontend/my-app/index.html:/app/index.html
- ./frontend/my-app/vite.config.js:/app/vite.config.js
command: ["npm", "run", "dev", "--", "--host"]
volumes:
chroma_data: