Spaces:
Sleeping
Sleeping
| FROM python:3.10-slim | |
| WORKDIR /app | |
| # Install ALL Chromium dependencies explicitly (fixed for Debian Trixie) | |
| RUN apt-get update && apt-get install -y \ | |
| wget \ | |
| gnupg \ | |
| curl \ | |
| # Core libraries for Chromium | |
| libnss3 \ | |
| libnspr4 \ | |
| libatk1.0-0 \ | |
| libatk-bridge2.0-0 \ | |
| libcups2 \ | |
| libdrm2 \ | |
| libdbus-1-3 \ | |
| libxkbcommon0 \ | |
| libxcomposite1 \ | |
| libxdamage1 \ | |
| libxfixes3 \ | |
| libxrandr2 \ | |
| libgbm1 \ | |
| libasound2 \ | |
| libpango-1.0-0 \ | |
| libpangocairo-1.0-0 \ | |
| libcairo2 \ | |
| libatspi2.0-0 \ | |
| libxshmfence1 \ | |
| libglib2.0-0 \ | |
| libx11-6 \ | |
| libx11-xcb1 \ | |
| libxcb1 \ | |
| libxext6 \ | |
| libxrender1 \ | |
| libxtst6 \ | |
| fonts-liberation \ | |
| libnss3-tools \ | |
| xdg-utils \ | |
| libgtk-3-0 \ | |
| libxss1 \ | |
| && rm -rf /var/lib/apt/lists/* | |
| # Copy requirements first for caching | |
| COPY requirements.txt . | |
| # Install Python dependencies | |
| RUN pip install --no-cache-dir -r requirements.txt | |
| # Set Playwright browser path and install browsers | |
| ENV PLAYWRIGHT_BROWSERS_PATH=/app/.playwright-browsers | |
| RUN python -m playwright install chromium | |
| # Copy application files | |
| COPY . . | |
| # Create data directories | |
| RUN mkdir -p /app/data/figma /app/data/website /app/data/comparisons /app/reports | |
| # Expose port | |
| EXPOSE 7860 | |
| # Run the app | |
| CMD ["python", "app.py"] |