Skip to content

Latest commit

 

History

History
65 lines (44 loc) · 2.67 KB

README.md

File metadata and controls

65 lines (44 loc) · 2.67 KB

LaTeX

LaTeX Logo

A convenient way to run LaTeX on various platform using Docker (latexmk, pdflatex...).

Dockerfile Docker Build Docker Stars Docker Pulls Docker Version

Example

Assuming that you have a file foo.tex in your current working directory that you want to convert into a PDF foo.pdf:

Mac/Linux

docker run --rm -t --user="$(id -u):$(id -g)" --net=none -v "$(pwd):/tmp" leplusorg/latex latexmk -outdir=/tmp -pdf /tmp/foo.tex

Windows

In cmd:

docker run --rm -t --net=none -v "%cd%:/tmp" leplusorg/latex latexmk -outdir=/tmp -pdf /tmp/foo.tex

In PowerShell:

docker run --rm -t --net=none -v "${PWD}:/tmp" leplusorg/latex latexmk -outdir=/tmp -pdf /tmp/foo.tex

Help

To know more command-line options of latexmk:

docker run --rm --net=none leplusorg/latex latexmk -h

texlive vs texlive-full

Version 1 of this image was using the texlive-full debian package to include as much TeX Live packages pre-installed as possible. But the resulting docker image was over 4 GB making it slow to download and breaking some CI/CD disk limits (including the free tier of GitHub Actions that I use). To keep the image usable by as many people as possible, I decided with version 2 and above to switch to the default texlive package.

If you need more TeX Live packages, you have the following options:

  • use version 1 of this docker image (i.e. leplusorg/latex:1.0.0@sha256:af368a8fda9fea612eb5f54025e0c0735c4d4a3ff67b0853e9e8a804a6a24d64).
  • use the image this fork is based on (i.e. aergus/latex:latest).

Request new tool

Please use this link (GitHub account required) to request that a new tool be added to the image. I am always interested in adding new capabilities to these images.