Compare commits

...

2 Commits

3 changed files with 42 additions and 9 deletions

View File

@ -4,7 +4,7 @@ ENV DEBIAN_FRONTEND=noninteractive PYTHONUNBUFFERED=1 LC_ALL=C.UTF-8 LANG=C.UTF-
RUN apt-get update && apt-get install -y --no-install-recommends \
ca-certificates curl git make emacs-nox python3 python3-pip python3-matplotlib \
latexmk biber texlive-full && rm -rf /var/lib/apt/lists/*
RUN useradd -m -u 1000 builder
RUN useradd -m -s /bin/bash builder || true
WORKDIR /work
USER builder
CMD ["bash", "-lc", "make VENUE=arxiv"]

View File

@ -1,14 +1,38 @@
# syntax=docker/dockerfile:1
FROM ubuntu:24.04
ENV DEBIAN_FRONTEND=noninteractive PYTHONUNBUFFERED=1 LC_ALL=C.UTF-8 LANG=C.UTF-8 PATH=/opt/TinyTeX/bin/x86_64-linux:$PATH
ENV DEBIAN_FRONTEND=noninteractive \
PYTHONUNBUFFERED=1 \
LC_ALL=C.UTF-8 \
LANG=C.UTF-8 \
TINYTEX_DIR=/opt/TinyTeX \
PATH=/opt/TinyTeX/bin/x86_64-linux:$PATH
# Tools that the TinyTeX installer uses (wget, tar, xz) + our stack
RUN apt-get update && apt-get install -y --no-install-recommends \
ca-certificates curl git make emacs-nox python3 python3-pip python3-matplotlib perl && \
rm -rf /var/lib/apt/lists/*
RUN curl -sL https://yihui.org/tinytex/install-unx.sh | sh -s - --admin --no-path && \
/opt/TinyTeX/bin/*/tlmgr path add && \
tlmgr install latexmk biber latex-bin biblatex hyperref geometry microtype etoolbox enumitem xcolor listings IEEEtran acmart elsarticle && \
tlmgr path add
RUN useradd -m -u 1000 builder
ca-certificates \
curl wget tar xz-utils \
git make \
emacs-nox \
python3 python3-pip python3-matplotlib \
perl \
&& rm -rf /var/lib/apt/lists/*
# Install TinyTeX *into /opt/TinyTeX* and set up tlmgr on PATH
# (we call tlmgr via its absolute path once, then rely on the symlinks it creates)
RUN curl -fsSL https://yihui.org/tinytex/install-unx.sh \
| TINYTEX_DIR="$TINYTEX_DIR" sh -s - --admin --no-path \
&& "$TINYTEX_DIR"/bin/*/tlmgr path add \
&& "$TINYTEX_DIR"/bin/*/tlmgr option repository http://mirror.ctan.org/systems/texlive/tlnet \
&& "$TINYTEX_DIR"/bin/*/tlmgr update --self \
&& "$TINYTEX_DIR"/bin/*/tlmgr install \
latexmk biber latex-bin biblatex hyperref geometry microtype etoolbox enumitem \
xcolor listings ieeetran acmart elsarticle \
&& fmtutil-sys --all
# Non-root user (maps nicer to host file perms)
RUN useradd -m -s /bin/bash builder || true
WORKDIR /work
USER builder
CMD ["bash", "-lc", "make VENUE=arxiv"]

View File

@ -20,6 +20,15 @@ clean:
latexmk -C
rm -f paper-*.pdf
debug:
emacs -Q --batch -l build.el --eval "(setenv \"VENUE\" \"$(VENUE)\")" \
--eval "(with-current-buffer (find-file-noselect \"paper.org\") (wes--inject-setupfile \"$(VENUE)\") (org-latex-export-to-latex))"
latexmk -C
latexmk -pdf -file-line-error -halt-on-error -interaction=nonstopmode -shell-escape paper.tex || true
@echo "---- paper.log (tail) ----"
@tail -n 200 paper.log || true
# Dockerized builds
DOCKER_IMAGE ?= polypaper:full
DOCKERFILE ?= Dockerfile.full