FROM python:3.9-slim WORKDIR /app COPY . /app # Install system dependencies for MediaPipe RUN apt-get update && apt-get install -y \ libglib2.0-0 \ libsm6 \ libxext6 \ libxrender-dev \ && rm -rf /var/lib/apt/lists/* # Install Python dependencies RUN pip install --no-cache-dir -r requirements.txt # Set Matplotlib cache directory ENV MPLCONFIGDIR=/tmp/matplotlib-cache CMD ["python", "app.py"]