2016-12-06 15:45:15 +00:00
|
|
|
FROM postgres:9.5
|
2016-09-11 23:52:31 +00:00
|
|
|
MAINTAINER Piero Toffanin <pt@masseranolabs.com>
|
2016-11-07 22:25:33 +00:00
|
|
|
|
|
|
|
ENV POSTGIS_MAJOR 2.3
|
|
|
|
|
2019-10-22 23:27:34 +00:00
|
|
|
RUN . /etc/os-release \
|
2019-10-22 23:21:57 +00:00
|
|
|
&& echo "deb http://deb.debian.org/debian "$VERSION_CODENAME"-backports main" >> /etc/apt/sources.list \
|
2017-07-14 13:57:18 +00:00
|
|
|
&& apt-get update \
|
2016-11-07 22:25:33 +00:00
|
|
|
&& apt-get install -y --no-install-recommends \
|
2016-12-06 15:45:15 +00:00
|
|
|
postgresql-$PG_MAJOR-postgis-$POSTGIS_MAJOR \
|
|
|
|
postgresql-$PG_MAJOR-postgis-$POSTGIS_MAJOR-scripts \
|
|
|
|
postgis \
|
2016-11-07 22:25:33 +00:00
|
|
|
&& rm -rf /var/lib/apt/lists/*
|
|
|
|
|
2016-09-11 23:52:31 +00:00
|
|
|
EXPOSE 5432
|
|
|
|
COPY init.sql /docker-entrypoint-initdb.d/init-db.sql
|
2017-05-24 00:53:36 +00:00
|
|
|
RUN chmod 644 /docker-entrypoint-initdb.d/init-db.sql
|