TestingI / Dockerfile
Baskar2005's picture
Upload 3 files
78a2b61 verified
raw
history blame
624 Bytes
# Use the official Playwright image (includes Python & Chromium dependencies)
FROM mcr.microsoft.com/playwright/python:v1.41.0-jammy
# Set working directory
WORKDIR /app
# Copy dependency file and install Python packages
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
# Install Chromium specifically (lightweight)
RUN playwright install chromium
# Copy all your project files
COPY . .
# Grant permissions (Hugging Face sometimes runs as non-root)
RUN chmod -R 777 /app
# Expose the port Hugging Face expects
EXPOSE 7860
# Run the application
CMD ["python", "app.py"]