Skip to content

Instantly share code, notes, and snippets.

@jeovazero
Created May 27, 2020 18:43
Show Gist options
  • Save jeovazero/52a2796145fe4e9f069e43fad7d4e1c8 to your computer and use it in GitHub Desktop.
Save jeovazero/52a2796145fe4e9f069e43fad7d4e1c8 to your computer and use it in GitHub Desktop.
Node + sqitch + chromium
FROM node:12.16.3-alpine3.10
# install sqitch
RUN apk add --no-cache --virtual build-deps \
g++ make \
perl-dev tzdata \
perl-dbd-pg postgresql-client && \
cp /usr/share/zoneinfo/UTC /etc/localtime && \
echo UTC > /etc/timezone && \
perl -MCPAN -e "CPAN::Shell->notest('install', 'App::Sqitch')" && \
apk del build-deps
# To use sqitch postgresql
RUN apk add --no-cache bash perl perl-dbd-pg postgresql-client
# install chromium from
# https://github.com/Zenika/alpine-chrome/blob/master/Dockerfile
RUN apk add --no-cache \
libstdc++ \
chromium \
harfbuzz \
nss \
freetype \
ttf-freefont \
&& rm -rf /var/cache/* \
&& mkdir /var/cache/apk
# From
# https://github.com/Zenika/alpine-chrome/blob/master/with-puppeteer/Dockerfile
ENV PUPPETEER_SKIP_CHROMIUM_DOWNLOAD 1
ENV PUPPETEER_EXECUTABLE_PATH /usr/bin/chromium-browser
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment