Saad110jb commited on
Commit
29c1be7
·
verified ·
1 Parent(s): 272d2d4

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +3 -4
Dockerfile CHANGED
@@ -1,9 +1,9 @@
1
  # 1. Use a standard Python image
2
  FROM python:3.10-slim
3
 
4
- # 2. Install system dependencies for OpenCV and AI
5
  RUN apt-get update && apt-get install -y \
6
- libgl1-mesa-glx \
7
  libglib2.0-0 \
8
  ffmpeg \
9
  && rm -rf /var/lib/apt/lists/*
@@ -16,12 +16,11 @@ ENV HOME=/home/user \
16
  WORKDIR $HOME/app
17
 
18
  # 4. Copy requirements and install via pip
19
- # We remove the 'uv.lock' and 'pyproject.toml' lines entirely
20
  COPY --chown=user requirements.txt .
21
  RUN pip install --no-cache-dir --upgrade -r requirements.txt
22
 
23
  # 5. Copy the rest of the project
24
  COPY --chown=user . .
25
 
26
- # 6. Start the FastAPI server on the required port
27
  CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"]
 
1
  # 1. Use a standard Python image
2
  FROM python:3.10-slim
3
 
4
+ # 2. Install system dependencies (Updated for Debian Trixie/Hugging Face)
5
  RUN apt-get update && apt-get install -y \
6
+ libgl1 \
7
  libglib2.0-0 \
8
  ffmpeg \
9
  && rm -rf /var/lib/apt/lists/*
 
16
  WORKDIR $HOME/app
17
 
18
  # 4. Copy requirements and install via pip
 
19
  COPY --chown=user requirements.txt .
20
  RUN pip install --no-cache-dir --upgrade -r requirements.txt
21
 
22
  # 5. Copy the rest of the project
23
  COPY --chown=user . .
24
 
25
+ # 6. Start the FastAPI server on port 7860
26
  CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"]