2016-09-27 23:46:36 +00:00
|
|
|
FROM mhart/alpine-node:latest
|
|
|
|
MAINTAINER Ryan Kes <ryan@andthensome.nl>
|
|
|
|
|
|
|
|
# Install pygments (for syntax highlighting)
|
|
|
|
RUN apk update && apk add bash && rm -rf /var/cache/apk/*
|
|
|
|
|
2016-09-29 11:26:02 +00:00
|
|
|
RUN apk add --no-cache \
|
|
|
|
xvfb \
|
|
|
|
# Additionnal dependencies for better rendering
|
|
|
|
ttf-freefont \
|
|
|
|
fontconfig \
|
|
|
|
dbus \
|
|
|
|
&& \
|
|
|
|
|
|
|
|
# Install wkhtmltopdf from `testing` repository
|
|
|
|
apk add qt5-qtbase-dev \
|
|
|
|
wkhtmltopdf \
|
|
|
|
--no-cache \
|
|
|
|
--repository http://dl-3.alpinelinux.org/alpine/edge/testing/ \
|
|
|
|
--allow-untrusted \
|
|
|
|
&& \
|
|
|
|
|
|
|
|
# Wrapper for xvfb
|
|
|
|
mv /usr/bin/wkhtmltopdf /usr/bin/wkhtmltopdf-origin && \
|
|
|
|
echo $'#!/usr/bin/env sh\n\
|
|
|
|
Xvfb :0 -screen 0 1024x768x24 -ac +extension GLX +render -noreset & \n\
|
|
|
|
DISPLAY=:0.0 wkhtmltopdf-origin $@ \n\
|
|
|
|
killall Xvfb\
|
|
|
|
' > /usr/bin/wkhtmltopdf && \
|
|
|
|
chmod +x /usr/bin/wkhtmltopdf
|
|
|
|
|
2016-09-27 23:46:36 +00:00
|
|
|
# Install hackmyresume
|
|
|
|
RUN npm install -g hackmyresume
|