Skip to content

Instantly share code, notes, and snippets.

@matanper
Last active April 8, 2019 22:03
Show Gist options
  • Save matanper/859ac6615f4959380690660376adb1be to your computer and use it in GitHub Desktop.
Save matanper/859ac6615f4959380690660376adb1be to your computer and use it in GitHub Desktop.
Postgres with jsquery extensions dockerfile
FROM mdillon/postgis:11-alpine
ENV JSQUERY_VERSION 1.1.1
RUN apk add --no-cache --virtual .fetch-deps \
ca-certificates \
openssl \
tar \
&& apk add --no-cache --virtual .build-deps \
g++ \
make \
&& apk add --no-cache --virtual .rundeps \
bison \
flex \
&& cd /tmp \
&& mkdir jsquery \
&& wget -O jsquery.tar.gz "https://github.com/postgrespro/jsquery/archive/ver_$JSQUERY_VERSION.tar.gz" \
&& tar \
--extract \
--file=jsquery.tar.gz \
--directory jsquery \
--strip-components 1 \
&& cd jsquery \
&& make USE_PGXS=1 \
&& make USE_PGXS=1 install \
&& apk del .build-deps .fetch-deps \
&& rm -rf /tmp/*
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment