-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
59 lines (54 loc) · 1.43 KB
/
docker-compose.yml
File metadata and controls
59 lines (54 loc) · 1.43 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
# docker-compose.yml
version: '3.8'
services:
# Backend API
backend:
build:
context: ./backend
dockerfile: Dockerfile
container_name: semantic-search-backend
ports:
- "8000:8000"
environment:
- MONGODB_URL=${MONGODB_URL}
- DATABASE_NAME=${DATABASE_NAME:-document_search}
- COLLECTION_NAME=${COLLECTION_NAME:-document_chunks}
- OPENAI_API_KEY=${OPENAI_API_KEY}
- GROQ_API_KEY=${GROQ_API_KEY}
- MAX_FILE_SIZE=${MAX_FILE_SIZE:-10485760}
- CHUNK_SIZE=${CHUNK_SIZE:-500}
- CHUNK_OVERLAP=${CHUNK_OVERLAP:-50}
- EMBEDDING_MODEL=${EMBEDDING_MODEL:-text-embedding-3-small}
- EMBEDDING_DIMENSIONS=${EMBEDDING_DIMENSIONS:-1536}
- HOST=0.0.0.0
- PORT=8000
volumes:
- ./backend/uploads:/app/uploads
restart: unless-stopped
networks:
- semantic-search-network
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8000/health"]
interval: 30s
timeout: 10s
retries: 3
start_period: 40s
# Frontend
frontend:
image: nginx:alpine
container_name: semantic-search-frontend
ports:
- "3000:80"
volumes:
- ./frontend:/usr/share/nginx/html:ro
- ./nginx.conf:/etc/nginx/conf.d/default.conf:ro
depends_on:
- backend
restart: unless-stopped
networks:
- semantic-search-network
networks:
semantic-search-network:
driver: bridge
volumes:
uploads: