Skip to content

Instantly share code, notes, and snippets.

@berkayakcay
Created July 22, 2020 12:46
Show Gist options
  • Save berkayakcay/1e4f0a355437f0db9c94935aa52283d2 to your computer and use it in GitHub Desktop.
Save berkayakcay/1e4f0a355437f0db9c94935aa52283d2 to your computer and use it in GitHub Desktop.
Install WKHTMLTOPDF on ASPNET Image
FROM mcr.microsoft.com/dotnet/core/aspnet:3.1.4-buster-slim
# # # # # # # # # # # # # # # # # # # # # # #
# INSTALL WKHTMLTOPDF
ENV WKHTMLTOX wkhtmltox_0.12.5-1.buster_amd64.deb
ENV BUILD_PACKAGES build-essential
ENV MAIN_PACKAGES fontconfig libfreetype6 libjpeg62-turbo libxext6 libpng16-16 libx11-6 libxcb1 libxrender1 xfonts-75dpi xfonts-base
COPY deps/$WKHTMLTOX /
RUN set -xe \
&& apt-get update -qq \
&& apt-get install --no-install-recommends -yq $BUILD_PACKAGES $MAIN_PACKAGES \
&& dpkg -i ${WKHTMLTOX} \
&& apt-get remove -y $BUILD_PACKAGES \
&& apt-get autoremove -y \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* \
&& rm -rf ${WKHTMLTOX} \
&& truncate -s 0 /var/log/*log
@selek55
Copy link

selek55 commented Nov 7, 2021

wkhtmltox_0.12.6-1.buster_amd64.deb

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment