From 9ca488baf98d59d32f8ac2bab173bb05f0ce72d9 Mon Sep 17 00:00:00 2001 From: Julius Freudenberger Date: Fri, 22 Apr 2022 15:07:56 +0200 Subject: [PATCH] Add helpful files for the docker setup --- docker/README.md | 6 ++++++ docker/docker-compose.yaml | 8 ++++++++ docker/run.bat | 3 +++ docker/run.sh | 4 ++++ workshop.tex | 2 +- 5 files changed, 22 insertions(+), 1 deletion(-) create mode 100644 docker/README.md create mode 100644 docker/docker-compose.yaml create mode 100644 docker/run.bat create mode 100755 docker/run.sh diff --git a/docker/README.md b/docker/README.md new file mode 100644 index 0000000..ada428d --- /dev/null +++ b/docker/README.md @@ -0,0 +1,6 @@ +# Docker setup for LaTeX + +To use the docker setup create the container using Docker Compose. +The source files have to reside in a subfolder called `data`. + +The batch or shell script provide an example on how to compile the document. diff --git a/docker/docker-compose.yaml b/docker/docker-compose.yaml new file mode 100644 index 0000000..df24d36 --- /dev/null +++ b/docker/docker-compose.yaml @@ -0,0 +1,8 @@ +version: "3" +services: + texlive: + image: texlive/texlive + volumes: + - ./data/:/latex + working_dir: /latex + tty: true diff --git a/docker/run.bat b/docker/run.bat new file mode 100644 index 0000000..ce9b492 --- /dev/null +++ b/docker/run.bat @@ -0,0 +1,3 @@ +docker-compose up -d +docker-compose exec texlive pdflatex file.tex +docker-compose down diff --git a/docker/run.sh b/docker/run.sh new file mode 100755 index 0000000..4209b0c --- /dev/null +++ b/docker/run.sh @@ -0,0 +1,4 @@ +#!/usr/bin/env sh +docker-compose up -d +docker-compose exec texlive pdflatex file.tex +docker-compose down diff --git a/workshop.tex b/workshop.tex index 4209f23..a1920ab 100644 --- a/workshop.tex +++ b/workshop.tex @@ -127,7 +127,7 @@ \item Im Projektverzeichnis \verb|pdflatex file.tex| \item automatisierter mit \verb|latexmk -pdf file.tex| \item In \TeX{}Maker \glqq{}Schnelles Übersetzen\grqq{} - \item mittels Docker und Docker Compose: %TODO + \item mittels Docker und Docker Compose (Anleitung im Git Repo) \item Outputfile \verb|file.pdf| als PDF-Datei im gleichen Verzeichnis \end{itemize} \end{frame}