peace2024 commited on
Commit
ad74cf1
·
1 Parent(s): a408f4b

docker update

Browse files
Files changed (1) hide show
  1. Dockerfile +2 -5
Dockerfile CHANGED
@@ -27,9 +27,6 @@ COPY requirements-hf.txt .
27
  RUN pip install --no-cache-dir --upgrade pip && \
28
  pip install --no-cache-dir -r requirements-hf.txt
29
 
30
- # Install PyTorch with CUDA support (will fall back to CPU if no GPU)
31
- RUN pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cpu
32
-
33
  # Copy the entire app source code
34
  COPY . .
35
 
@@ -43,5 +40,5 @@ EXPOSE 7860
43
  HEALTHCHECK --interval=30s --timeout=30s --start-period=5s --retries=3 \
44
  CMD curl -f http://localhost:7860/docs || exit 1
45
 
46
- # Run the FastAPI app via Uvicorn with optimized settings
47
- CMD ["uvicorn", "app.main:app", "--host", "0.0.0.0", "--port", "7860", "--workers", "1"]
 
27
  RUN pip install --no-cache-dir --upgrade pip && \
28
  pip install --no-cache-dir -r requirements-hf.txt
29
 
 
 
 
30
  # Copy the entire app source code
31
  COPY . .
32
 
 
40
  HEALTHCHECK --interval=30s --timeout=30s --start-period=5s --retries=3 \
41
  CMD curl -f http://localhost:7860/docs || exit 1
42
 
43
+ # Run the FastAPI app via Uvicorn
44
+ CMD ["uvicorn", "app.main:app", "--host", "0.0.0.0", "--port", "7860"]