From 4800a5195708c66a015725a3ff41795f55de8968 Mon Sep 17 00:00:00 2001 From: claude Date: Sun, 31 May 2026 21:52:56 +0000 Subject: [PATCH] Use a curated TeX Live set instead of near-full to speed up builds MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The previous install expanded texlive-full (minus -doc/-lang-), pulling in essentially every CTAN package plus inkscape's large GTK GUI tree — ~20 min and several GB. Replace it with a curated set of meta-packages that covers the vast majority of documents: latex base/recommended/extra, recommended fonts, plain-generic, science (math/physics), xetex, luatex, bibtex-extra, extra-utils (texcount), plus latexmk/biber/chktex/pygments. Smaller and faster to build. Documents needing an omitted package can have the relevant texlive-* collection added back. Drops inkscape (only used for auto SVG->PDF conversion) to avoid its heavy GUI dependency chain. Co-Authored-By: Claude Opus 4.8 --- server-ce/Dockerfile-base | 34 ++++++++++++++++++++++------------ 1 file changed, 22 insertions(+), 12 deletions(-) diff --git a/server-ce/Dockerfile-base b/server-ce/Dockerfile-base index 7fa917713a..1ab78d93cd 100644 --- a/server-ce/Dockerfile-base +++ b/server-ce/Dockerfile-base @@ -72,21 +72,31 @@ RUN mkdir -p /opt/quarto-extensions \ # Install TeX Live (for compiling .tex projects with latexmk) # ----------------------------------------------------------------------- # Verso compiles .qmd with Quarto and .tex with latexmk; both engines live -# side by side. We install (almost) all of texlive-full, excluding the -doc -# and -lang- packages to keep the download from being needlessly huge while -# still providing a complete LaTeX toolchain (latexmk, xetex, lualatex, -# biber, texcount, chktex, synctex, etc.). +# side by side. Rather than (almost) all of texlive-full — which pulls in +# every CTAN package and takes ~20 min to build — we install a curated set +# of meta-packages covering the vast majority of real documents: the latex +# base/recommended/extra collections, recommended fonts, science/math +# packages, both alternative engines (xetex, luatex), and bibliography +# tooling. This is a few GB smaller and noticeably faster to build. +# +# If a document needs a package not included here, add the relevant +# texlive-* collection below (e.g. texlive-fonts-extra, texlive-publishers, +# texlive-humanities) and rebuild. We deliberately omit inkscape, whose GTK +# GUI dependency tree is large and only needed for auto SVG->PDF conversion. # ----------------------------------------------------------------------- RUN apt-get update \ -&& apt-cache depends texlive-full \ - | grep "Depends: " \ - | grep -v -- "-doc" \ - | grep -v -- "-lang-" \ - | sed 's/Depends: //' \ - | xargs apt-get install -y --no-install-recommends \ && apt-get install -y --no-install-recommends \ - texlive-xetex texlive-luatex texlive-bibtex-extra biber \ - texlive-extra-utils latexmk chktex fontconfig inkscape python3-pygments \ + texlive-latex-base \ + texlive-latex-recommended \ + texlive-latex-extra \ + texlive-fonts-recommended \ + texlive-plain-generic \ + texlive-science \ + texlive-xetex \ + texlive-luatex \ + texlive-bibtex-extra \ + texlive-extra-utils \ + latexmk biber chktex fontconfig python3-pygments \ && rm -rf /var/lib/apt/lists/*