docker compose file added for deployment

This commit is contained in:
2026-01-22 22:34:12 +05:30
parent 9d7109b60f
commit c76d533783
13 changed files with 267 additions and 4 deletions

30
backend/Dockerfile Normal file
View File

@@ -0,0 +1,30 @@
# Use official lightweight Python image
FROM python:3.9-slim
# Install system dependencies
# tesseract-ocr: for pytesseract
# poppler-utils: for pdf2image
# libtesseract-dev: development headers
RUN apt-get update && apt-get install -y \
tesseract-ocr \
poppler-utils \
libtesseract-dev \
&& rm -rf /var/lib/apt/lists/*
# Set working directory
WORKDIR /app
# Copy requirements first to leverage Docker cache
COPY requirements.txt .
# Install Python dependencies
RUN pip install --no-cache-dir -r requirements.txt
# Copy the rest of the application code
COPY . .
# Expose port (default for Uvicorn)
EXPOSE 8000
# Run the application
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "8000"]

View File

@@ -10,3 +10,4 @@ imap-tools
apscheduler
python-dotenv
pdfplumber
pdf2image