-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
36 lines (27 loc) · 1.58 KB
/
Dockerfile
File metadata and controls
36 lines (27 loc) · 1.58 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
# ── PDFGezo Dockerfile ────────────────────────────────────────────────
# Python 3.11 slim base + system deps (Poppler, Ghostscript, LibreOffice)
# ──────────────────────────────────────────────────────────────────────
FROM python:3.11-slim
# Prevent interactive prompts during apt installs
ENV DEBIAN_FRONTEND=noninteractive
# ── System dependencies ──────────────────────────────────────────────
RUN apt-get update && apt-get install -y --no-install-recommends \
poppler-utils \
ghostscript \
libreoffice \
fonts-liberation \
fonts-dejavu-core \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
# ── App setup ────────────────────────────────────────────────────────
WORKDIR /app
# Install Python dependencies first (cache layer)
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
# Copy application code
COPY . .
# Create runtime directories
RUN mkdir -p uploads outputs
# ── Runtime ──────────────────────────────────────────────────────────
EXPOSE 5000
CMD ["python", "app.py"]