Spaces:
Runtime error
Runtime error
File size: 781 Bytes
7de112c caef88e 7af0500 caef88e 7de112c a011561 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 |
# Use the specific Python version as the base image
FROM python:3.7.6
# Set the working directory inside the container
WORKDIR /app
# Create a directory for Matplotlib configuration
RUN mkdir -p /app/matplotlib-config && chmod 777 /app/matplotlib-config
# Set environment variable for Matplotlib config
ENV MPLCONFIGDIR=/app/matplotlib-config
# Copy your application's requirements file to the container
COPY requirements.txt .
# Install the dependencies
RUN pip install --no-cache-dir -r requirements.txt
RUN pip install detectron2 -f \
https://dl.fbaipublicfiles.com/detectron2/wheels/cu102/torch1.7/index.html
# Copy the rest of your application code to the container
COPY . .
# Set the command to run your application
CMD ["gunicorn", "-b", "0.0.0.0:8888", "app:app"]
|