2
2
# The timescaledb version doesn't need to mactch the postgres version here
3
3
FROM timescale/timescaledb:latest-pg14 AS tools
4
4
5
- # FROM quay.io/panubo/postgres:14-debian13 AS oldversions
5
+ FROM quay.io/panubo/postgres:14-debian13 AS oldversions
6
6
7
7
FROM docker.io/postgres:14-trixie
8
8
9
- ENV POSTGIS_VERSION=3.1.8 POSTGIS_SHA256=54254fb57070ce44d1da9434f472e0a82df0ef24321c2b9a22c449f756e278e7
10
- ENV TIMESCALEDB_VERSION=2.5.2 TIMESCALEDB_SHA256=b1a20832189c22ce378f009f9a24ef1db61d7131f7f79bde74fdcde87bcf2d7c
9
+ ENV TIMESCALEDB_VERSION=2.6.1 TIMESCALEDB_SHA256=226af207105cc9e2d1744b303e475204a947047103f0e5697de4e8949e4dde75
11
10
ENV WALG_VERSION=3.0.7 WALG_AMD64_SHA256=76d51ed915165d45314bc947300b9d1776adb2d875d857f580a730fd6f66900e WALG_AARCH64_SHA256=fcf25aac732f66e77e121e9d287a08d8bf867c604b81cb6fcfff2d6c692d38c9
12
11
ENV POSTGRES_INITDB_ARGS="--data-checksums"
13
12
@@ -19,22 +18,6 @@ RUN set -x \
19
18
&& rm -rf /var/lib/apt/lists/* \
20
19
;
21
20
22
- # Install PostGIS extension
23
- RUN set -x \
24
- && apt-get update \
25
- && apt-get -y install build-essential libsfcgal-dev libxml2-dev libgdal-dev libproj-dev libjson-c-dev libprotobuf-c-dev libgeos-dev libsfcgal2 libgdal36 libjson-c5 libproj25 libgeos-c1v5 libprotobuf-c1 protobuf-c-compiler xsltproc docbook-xsl docbook-mathml postgresql-server-dev-${PG_MAJOR} \
26
- && DIR=$(mktemp -d) && cd ${DIR} \
27
- && curl -s -L https://download.osgeo.org/postgis/source/postgis-${POSTGIS_VERSION}.tar.gz -o postgis.tar.gz \
28
- && sha256sum postgis.tar.gz \
29
- && echo "${POSTGIS_SHA256} postgis.tar.gz" | sha256sum -c - \
30
- && tar -xzf postgis.tar.gz --strip-components=1 \
31
- && ./configure --with-sfcgal && make -j 4 && make install \
32
- && apt-get -y remove build-essential libsfcgal-dev libxml2-dev libgdal-dev libproj-dev libjson-c-dev libprotobuf-c-dev libgeos-dev xsltproc docbook-xsl docbook-mathml postgresql-server-dev-${PG_MAJOR} \
33
- && apt-get -y autoremove && apt-get clean \
34
- && rm -rf /var/lib/apt/lists/* ${DIR} \
35
- && sed -r -i "s/[#]*\s *(shared_preload_libraries)\s *=\s *'(.*)'/\1 = 'postgis-3,\2 '/;s/,'/'/" /usr/share/postgresql/postgresql.conf.sample \
36
- ;
37
-
38
21
# Build and install TimescaleDB extension
39
22
RUN set -x \
40
23
&& apt-get update \
@@ -69,6 +52,16 @@ RUN set -x \
69
52
&& rm -rf ${DIR} \
70
53
;
71
54
55
+ # Install postgis
56
+ RUN set -x \
57
+ && apt-get update \
58
+ && apt-get install -y postgresql-${PG_MAJOR}-postgis \
59
+ && apt-get -y autoremove \
60
+ && apt-get clean \
61
+ && rm -rf /var/lib/apt/lists/* \
62
+ && rm -rf ${DIR} \
63
+ ;
64
+
72
65
# Install pglogical
73
66
RUN set -x \
74
67
&& apt-get update \
@@ -102,8 +95,8 @@ CMD ["postgres"]
102
95
103
96
COPY --from=tools /usr/local/bin/timescaledb-tune /usr/local/bin/timescaledb-parallel-copy /usr/local/bin/
104
97
105
- # COPY --from=oldversions /usr/lib/postgresql/14/lib/timescaledb-*.so /usr/lib/postgresql/14/lib/
106
- # COPY --from=oldversions /usr/share/postgresql/14/extension/timescaledb--*.sql /usr/share/postgresql/14/extension/
98
+ COPY --from=oldversions /usr/lib/postgresql/14/lib/timescaledb-*.so /usr/lib/postgresql/14/lib/
99
+ COPY --from=oldversions /usr/share/postgresql/14/extension/timescaledb--*.sql /usr/share/postgresql/14/extension/
107
100
108
101
# COPY --from=oldversions /usr/lib/postgresql/14/lib/postgis-*.so /usr/lib/postgresql/14/lib/
109
102
# COPY --from=oldversions /usr/lib/postgresql/14/lib/postgis_topology-*.so /usr/lib/postgresql/14/lib/
0 commit comments