Spaces:
Sleeping
Sleeping
File size: 444 Bytes
21f7838 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
# 1️⃣ Use an official slim Python image
FROM python:3.9-slim
# 2️⃣ Set working directory
WORKDIR /app
# 3️⃣ Copy requirements first
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
# 4️⃣ Copy all files from the root of your project (app.py, .h5, .json, results dir, etc.)
COPY . .
# 5️⃣ Expose the port
EXPOSE 7860
# 6️⃣ Command to run the app
CMD ["python", "app.py"]
|