Spaces:
Runtime error
Runtime error
File size: 973 Bytes
9a1e7ea 8759831 9a1e7ea 8759831 9a1e7ea 8759831 9a1e7ea 8759831 9a1e7ea 8759831 9a1e7ea 8759831 9a1e7ea 8759831 9a1e7ea 8759831 | 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 27 28 29 30 31 32 33 34 35 36 37 | # TreyOS — HuggingFace Spaces Docker Image
FROM python:3.12-slim
# System deps + Chromium deps for Playwright
RUN apt-get update && apt-get install -y --no-install-recommends \
curl procps \
# Chromium / Playwright deps
libnss3 libatk1.0-0 libatk-bridge2.0-0 libcups2 libdrm2 \
libxkbcommon0 libxcomposite1 libxdamage1 libxfixes3 libxrandr2 \
libgbm1 libasound2 libpango-1.0-0 libpangocairo-1.0-0 \
libgtk-3-0 libx11-xcb1 libxcb-dri3-0 \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /app
# Python deps
COPY backend/requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
# Install Playwright Chromium browser
RUN playwright install chromium
# App files
COPY backend/ ./backend/
COPY frontend/ ./frontend/
ENV TREY_ROOT=/app
ENV PORT=7860
EXPOSE 7860
HEALTHCHECK --interval=30s --timeout=10s \
CMD curl -f http://localhost:7860/api/health || exit 1
CMD ["uvicorn", "backend.main:app", "--host", "0.0.0.0", "--port", "7860"]
|