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
26 lines
642 B
# Use an official Python runtime as a parent image
|
|
FROM python:3.10-slim
|
|
|
|
# Set the working directory in the container
|
|
WORKDIR /app
|
|
|
|
# Install system dependencies
|
|
RUN apt-get update && apt-get install -y \
|
|
poppler-utils \
|
|
tesseract-ocr \
|
|
&& rm -rf /var/lib/apt/lists/*
|
|
|
|
# Copy only the files necessary for pip installations
|
|
COPY requirements.txt .
|
|
|
|
# Install Python dependencies
|
|
RUN pip install --upgrade pip && pip install -r requirements.txt watchdog
|
|
|
|
# Copy the rest of the application
|
|
COPY . .
|
|
|
|
# Make port 5000 available to the world outside this container
|
|
EXPOSE 5000
|
|
|
|
# Run the app using Python directly
|
|
CMD ["python", "app.py"]
|