AbhishekPathak01 commited on
Commit
1830ba1
·
1 Parent(s): 242f848
Files changed (1) hide show
  1. Dockerfile +3 -10
Dockerfile CHANGED
@@ -1,6 +1,5 @@
1
  FROM python:3.11-slim
2
 
3
- # System dependencies
4
  RUN apt-get update && apt-get install -y \
5
  gcc \
6
  g++ \
@@ -9,25 +8,19 @@ RUN apt-get update && apt-get install -y \
9
 
10
  WORKDIR /app
11
 
12
- # Install Python dependencies
13
  COPY requirements.txt .
14
  RUN pip install --no-cache-dir -r requirements.txt
15
 
16
- # Copy application code
17
  COPY backend/ ./backend/
18
  COPY data/ ./data/
19
 
20
  WORKDIR /app/backend
21
 
22
- # Create vector store directory
23
  RUN mkdir -p vector_store/faiss_index
24
 
25
- # Expose port
26
- EXPOSE 8000
27
 
28
- # Health check
29
  HEALTHCHECK --interval=30s --timeout=10s --start-period=60s --retries=3 \
30
- CMD curl -f http://localhost:8000/health || exit 1
31
 
32
- # Run application
33
- CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "8000", "--workers", "1"]
 
1
  FROM python:3.11-slim
2
 
 
3
  RUN apt-get update && apt-get install -y \
4
  gcc \
5
  g++ \
 
8
 
9
  WORKDIR /app
10
 
 
11
  COPY requirements.txt .
12
  RUN pip install --no-cache-dir -r requirements.txt
13
 
 
14
  COPY backend/ ./backend/
15
  COPY data/ ./data/
16
 
17
  WORKDIR /app/backend
18
 
 
19
  RUN mkdir -p vector_store/faiss_index
20
 
21
+ EXPOSE 7860
 
22
 
 
23
  HEALTHCHECK --interval=30s --timeout=10s --start-period=60s --retries=3 \
24
+ CMD curl -f http://localhost:7860/health || exit 1
25
 
26
+ CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860", "--workers", "1"]