Spaces:
Running
Running
Upload folder using huggingface_hub
Browse files- Dockerfile +1 -8
Dockerfile
CHANGED
|
@@ -2,22 +2,15 @@ FROM python:3.11-slim
|
|
| 2 |
|
| 3 |
WORKDIR /app
|
| 4 |
|
| 5 |
-
# Install system dependencies
|
| 6 |
RUN apt-get update && \
|
| 7 |
apt-get install -y git curl && \
|
| 8 |
rm -rf /var/lib/apt/lists/*
|
| 9 |
|
| 10 |
-
# Copy requirements first — Docker layer caching
|
| 11 |
-
# If requirements.txt hasn't changed, this layer is reused
|
| 12 |
-
# and pip install is skipped on rebuild. Saves 5+ minutes.
|
| 13 |
COPY requirements.txt .
|
| 14 |
RUN pip install --no-cache-dir -r requirements.txt
|
| 15 |
|
| 16 |
-
# Copy all project files
|
| 17 |
COPY . .
|
| 18 |
|
| 19 |
-
# HuggingFace Spaces requires port 7860
|
| 20 |
EXPOSE 7860
|
| 21 |
|
| 22 |
-
|
| 23 |
-
CMD ["uvicorn", "api.main:app", "--host", "0.0.0.0", "--port", "7860"]
|
|
|
|
| 2 |
|
| 3 |
WORKDIR /app
|
| 4 |
|
|
|
|
| 5 |
RUN apt-get update && \
|
| 6 |
apt-get install -y git curl && \
|
| 7 |
rm -rf /var/lib/apt/lists/*
|
| 8 |
|
|
|
|
|
|
|
|
|
|
| 9 |
COPY requirements.txt .
|
| 10 |
RUN pip install --no-cache-dir -r requirements.txt
|
| 11 |
|
|
|
|
| 12 |
COPY . .
|
| 13 |
|
|
|
|
| 14 |
EXPOSE 7860
|
| 15 |
|
| 16 |
+
CMD ["uvicorn", "api.main:app", "--host", "0.0.0.0", "--port", "7860"]
|
|
|