You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

26 lines
642 B

8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
  1. # Use an official Python runtime as a parent image
  2. FROM python:3.10-slim
  3. # Set the working directory in the container
  4. WORKDIR /app
  5. # Install system dependencies
  6. RUN apt-get update && apt-get install -y \
  7. poppler-utils \
  8. tesseract-ocr \
  9. && rm -rf /var/lib/apt/lists/*
  10. # Copy only the files necessary for pip installations
  11. COPY requirements.txt .
  12. # Install Python dependencies
  13. RUN pip install --upgrade pip && pip install -r requirements.txt watchdog
  14. # Copy the rest of the application
  15. COPY . .
  16. # Make port 5000 available to the world outside this container
  17. EXPOSE 5000
  18. # Run the app using Python directly
  19. CMD ["python", "app.py"]