diff options
| author | kj_sh604 | 2026-02-13 23:38:05 -0500 |
|---|---|---|
| committer | kj_sh604 | 2026-02-13 23:38:05 -0500 |
| commit | eaf6b4a594c9a42076caf5766d08b40019a77b78 (patch) | |
| tree | aa20fcf16f9ebf2e231e5a3864164e527c5ca61e | |
| parent | 1f1abae197f3fd58da2c3ab7a0a198bec3bbb847 (diff) | |
feat: docker 🚢🙂
| -rw-r--r-- | Dockerfile | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..8fe61b3 --- /dev/null +++ b/Dockerfile | |||
| @@ -0,0 +1,40 @@ | |||
| 1 | FROM ubuntu:24.04 | ||
| 2 | |||
| 3 | ENV PYTHONUNBUFFERED=1 | ||
| 4 | |||
| 5 | # system deps + libreoffice fresh ppa | ||
| 6 | RUN apt-get update && \ | ||
| 7 | apt-get install -y --no-install-recommends \ | ||
| 8 | software-properties-common \ | ||
| 9 | ca-certificates && \ | ||
| 10 | add-apt-repository -y ppa:libreoffice/ppa && \ | ||
| 11 | apt-get update && \ | ||
| 12 | apt-get install -y --no-install-recommends \ | ||
| 13 | python3 \ | ||
| 14 | python3-pip \ | ||
| 15 | python3-venv \ | ||
| 16 | libreoffice \ | ||
| 17 | poppler-utils \ | ||
| 18 | fonts-liberation \ | ||
| 19 | fonts-dejavu-core && \ | ||
| 20 | apt-get clean && \ | ||
| 21 | rm -rf /var/lib/apt/lists/* | ||
| 22 | |||
| 23 | # python deps | ||
| 24 | COPY src/requirements.txt /tmp/requirements.txt | ||
| 25 | RUN pip3 install --no-cache-dir --break-system-packages -r /tmp/requirements.txt | ||
| 26 | |||
| 27 | # kjandoc binary -> /usr/local/bin | ||
| 28 | COPY src/kjandoc /usr/local/bin/kjandoc | ||
| 29 | RUN chmod +x /usr/local/bin/kjandoc | ||
| 30 | |||
| 31 | # demoware | ||
| 32 | WORKDIR /app | ||
| 33 | COPY demoware/ /app/ | ||
| 34 | |||
| 35 | # storage dirs | ||
| 36 | RUN mkdir -p /app/uploads /app/output | ||
| 37 | |||
| 38 | EXPOSE 8080 | ||
| 39 | |||
| 40 | CMD ["python3", "server.py"] \ No newline at end of file | ||
