From d20c3131484246b177f4ec8c3fadd321e3834b2b Mon Sep 17 00:00:00 2001 From: George Song Date: Tue, 9 Mar 2021 09:40:44 -0800 Subject: [PATCH] build: WIP Dockerfile Addresses #1043 --- docker/images/Dockerfile.build-pdf | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 docker/images/Dockerfile.build-pdf diff --git a/docker/images/Dockerfile.build-pdf b/docker/images/Dockerfile.build-pdf new file mode 100644 index 00000000000..2153b725871 --- /dev/null +++ b/docker/images/Dockerfile.build-pdf @@ -0,0 +1,27 @@ +FROM ubuntu:focal + +ARG PANDOC_VERSION=2.12 +ARG PANDOC_DEB=pandoc-2.12-1-amd64.deb +ARG WKHTML_TO_PDF_VERSION=0.12.6-1 +ARG WKHTML_TO_PDF_DEB=wkhtmltox_${WKHTML_TO_PDF_VERSION}.focal_amd64.deb + +RUN apt-get update && apt-get install --no-install-recommends -y \ + python3 \ + wget \ + && apt-get clean \ + && rm -rf /var/lib/apt/lists/* + +# Install Pandoc +RUN wget --no-check-certificate -P /tmp https://github.com/jgm/pandoc/releases/download/${PANDOC_VERSION}/${PANDOC_DEB} \ + && apt-get install --no-install-recommends -y /tmp/${PANDOC_DEB} \ + && apt-get clean \ + && rm -rf /var/lib/apt/lists/* \ + && rm -rf /tmp/* + +# Install wkhtmltopdf +RUN wget --no-check-certificate -P /tmp https://github.com/wkhtmltopdf/packaging/releases/download/${WKHTML_TO_PDF_VERSION}/${WKHTML_TO_PDF_DEB} \ + && apt-get update \ + && apt-get install --no-install-recommends -y /tmp/${WKHTML_TO_PDF_DEB} \ + && apt-get clean \ + && rm -rf /var/lib/apt/lists/* \ + && rm -rf /tmp/*