Pest-detection / Dockerfile
Fadhili Sumaye
Fix Dockerfile dependencies by replacing obsolete libgl1-mesa-glx with libgl1
6e61656
Raw
History Blame Contribute Delete
422 Bytes
FROM python:3.9-slim
RUN useradd -m -u 1000 user
WORKDIR /app
RUN apt-get update && apt-get install -y \
libgl1 \
libglib2.0-0 \
&& rm -rf /var/lib/apt/lists/*
COPY backend/requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
COPY --chown=user backend/ .
RUN mkdir -p uploads && chown -R user:user /app
ENV PORT=7860
ENV HOME=/home/user
USER user
EXPOSE 7860
CMD ["python", "app.py"]