Skip to content

Instantly share code, notes, and snippets.

@theirix
Created July 3, 2017 06:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save theirix/0876a5047a7da5da961444d2fd78c2e7 to your computer and use it in GitHub Desktop.
Save theirix/0876a5047a7da5da961444d2fd78c2e7 to your computer and use it in GitHub Desktop.
Dockerfile for reproducing wkhtmltopdf/#1769
# run:
# docker run -it --rm -v `pwd`:/srv theirix/wkhtmltopdf-test
# then view test.pdf
FROM debian:9
RUN apt-get update && apt-get install -y locales xz-utils wget unzip libxrender1 libfontconfig xserver-common
RUN localedef -i en_US -c -f UTF-8 en_US.UTF-8
ENV LANG en_US.UTF-8
RUN locale
RUN wget -q https://github.com/wkhtmltopdf/wkhtmltopdf/releases/download/0.12.4/wkhtmltox-0.12.4_linux-generic-amd64.tar.xz
RUN wget -q http://omniverse.ru/public/wkhtmltopdf-test.zip
RUN tar xf wkhtmltox-0.12.4_linux-generic-amd64.tar.xz
RUN unzip wkhtmltopdf-test.zip
VOLUME /srv
CMD ./wkhtmltox/bin/wkhtmltopdf wkhtmltopdf-test/main.html wkhtmltopdf-test/TestPage.html wkhtmltopdf-test/ТестоваяСтраница.html /srv/test.pdf
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment