Skip to content

Instantly share code, notes, and snippets.

@ksafranski
Created November 30, 2018 13:33
Show Gist options
  • Save ksafranski/b38cc30d8c31edc30c1e6306c93b53b6 to your computer and use it in GitHub Desktop.
Save ksafranski/b38cc30d8c31edc30c1e6306c93b53b6 to your computer and use it in GitHub Desktop.
FROM mhart/alpine-node:8.9
# Dependencies
RUN apk --no-cache add --virtual builds-deps build-base python vim
# Specify pgweb version
ENV PGWEB_VERSION=0.9.12 \
PGWEB_USER=pgweb \
PGWEB_DIR=/app/pgweb
# Install dependencies
RUN apk update && \
apk add --no-cache build-base \
chromium \
chromium-chromedriver \
udev \
ttf-freefont \
chromium \
util-linux \
readline-dev \
openssl-dev \
zlib-dev \
libxml2-dev \
glib-lang \
wget \
gnupg \
unzip \
ca-certificates && \
wget https://github.com/sosedoff/pgweb/releases/download/v$PGWEB_VERSION/pgweb_linux_amd64.zip -O /tmp/pgweb-$PGWEB_VERSION.zip && \
mkdir -p $PGWEB_DIR && \
unzip /tmp/pgweb-$PGWEB_VERSION.zip -d $PGWEB_DIR && \
apk --purge del build-base openssl-dev zlib-dev libxml2-dev wget gnupg unzip ca-certificates && \
rm -r /tmp/pgweb-$PGWEB_VERSION.zip /var/cache/apk/* && \
yarn global add pm2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment