Spaces:
Sleeping
Sleeping
File size: 486 Bytes
35b3531 36e19ea |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 |
# Use a slim Python image as the base
FROM python:3.11-slim
# Set the working directory to /app
WORKDIR /app
# Copy only the necessary files to the container
COPY app.py requirements.txt ./
COPY src ./src
COPY artifacts ./artifacts
COPY templates ./templates
# Install packages and clean up
RUN pip install -r requirements.txt && apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
# Run your Flask app with Gunicorn
CMD ["gunicorn", "app:app", "--bind", "0.0.0.0:7860"]] |