diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index f7374a40..5db918d6 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -15,17 +15,14 @@ jobs: make-docker-images: strategy: matrix: - postgres: [12, 13, 14, 15, 16rc1] + postgres: [12, 13, 14, 15, 16] postgis: ['3.4'] variant: [default, alpine] include: - - postgres: 14 - postgis: master - variant: default - postgres: 15 postgis: master variant: default - - postgres: 16rc1 + - postgres: 16 postgis: master variant: default - postgres: 11 diff --git a/15-master/Dockerfile b/15-master/Dockerfile index fd1b960f..8a20da1b 100644 --- a/15-master/Dockerfile +++ b/15-master/Dockerfile @@ -88,7 +88,7 @@ ENV DOCKER_CMAKE_BUILD_TYPE=${DOCKER_CMAKE_BUILD_TYPE} # one can benefit from the latest CGAL patches while avoiding compatibility issues. ARG CGAL_GIT_BRANCH ENV CGAL_GIT_BRANCH=${CGAL_GIT_BRANCH} -ENV CGAL5X_GIT_HASH 9c9a2690fb4916c249342f3c2dcd08ccd99b7ac8 +ENV CGAL5X_GIT_HASH 3c8e2053721271119499506ea1d8a49dee89e30c ENV SFCGAL_GIT_HASH fc4dc5640e402c8b00426b5a3562324226725df9 RUN set -ex \ && mkdir -p /usr/src \ @@ -122,7 +122,7 @@ RUN set -ex \ && rm -fr /usr/src/cgal # proj -ENV PROJ_GIT_HASH 4a14240a606e5d2ba091a922f52cd3f38dba258c +ENV PROJ_GIT_HASH d4ebd920c1e1ecd0e192790ab4fdb98c7b982176 RUN set -ex \ && cd /usr/src \ && git clone https://github.com/OSGeo/PROJ.git \ @@ -152,7 +152,7 @@ RUN set -ex \ && rm -fr /usr/src/PROJ # geos -ENV GEOS_GIT_HASH 15185e65b3e7bc671cf693c97cf103125fb4a171 +ENV GEOS_GIT_HASH 1033161eca3684e0d9479daeafd35a4e0fb1800e RUN set -ex \ && cd /usr/src \ && git clone https://github.com/libgeos/geos.git \ @@ -168,7 +168,7 @@ RUN set -ex \ && rm -fr /usr/src/geos # gdal -ENV GDAL_GIT_HASH 7dec7e98b6be558ef76e1c17262994610a532573 +ENV GDAL_GIT_HASH 43e51bc48e7d48795ae60731ddc1414611ec5d3e RUN set -ex \ && cd /usr/src \ && git clone https://github.com/OSGeo/gdal.git \ @@ -301,11 +301,11 @@ COPY --from=builder /usr/local /usr/local ARG CGAL_GIT_BRANCH ENV CGAL_GIT_BRANCH=${CGAL_GIT_BRANCH} -ENV CGAL5X_GIT_HASH 9c9a2690fb4916c249342f3c2dcd08ccd99b7ac8 +ENV CGAL5X_GIT_HASH 3c8e2053721271119499506ea1d8a49dee89e30c ENV SFCGAL_GIT_HASH fc4dc5640e402c8b00426b5a3562324226725df9 -ENV PROJ_GIT_HASH 4a14240a606e5d2ba091a922f52cd3f38dba258c -ENV GEOS_GIT_HASH 15185e65b3e7bc671cf693c97cf103125fb4a171 -ENV GDAL_GIT_HASH 7dec7e98b6be558ef76e1c17262994610a532573 +ENV PROJ_GIT_HASH d4ebd920c1e1ecd0e192790ab4fdb98c7b982176 +ENV GEOS_GIT_HASH 1033161eca3684e0d9479daeafd35a4e0fb1800e +ENV GDAL_GIT_HASH 43e51bc48e7d48795ae60731ddc1414611ec5d3e # Minimal command line test ( fail fast ) RUN set -ex \ @@ -324,7 +324,7 @@ RUN set -ex \ || echo "ogr2ogr missing PostgreSQL driver" && exit 1 # install postgis -ENV POSTGIS_GIT_HASH cc7a8ca0871ae2114e920aa7472c639ec80abe7d +ENV POSTGIS_GIT_HASH d7b58458ea7cf8157d09f59e955820d3a4321892 RUN set -ex \ && apt-get update \ @@ -336,6 +336,8 @@ RUN set -ex \ build-essential \ ca-certificates \ cmake \ + docbook-xml \ + docbook5-xml \ g++ \ git \ libboost-all-dev \ @@ -350,6 +352,7 @@ RUN set -ex \ libtiff-dev \ libtool \ libxml2-dev \ + libxml2-utils \ make \ pkg-config \ postgresql-server-dev-$PG_MAJOR \ @@ -409,6 +412,8 @@ RUN set -ex \ bison \ build-essential \ cmake \ + docbook-xml \ + docbook5-xml \ g++ \ git \ libboost-all-dev \ @@ -422,6 +427,7 @@ RUN set -ex \ libtiff-dev \ libtool \ libxml2-dev \ + libxml2-utils \ make \ pkg-config \ postgresql-server-dev-$PG_MAJOR \ diff --git a/16rc1-3.4/Dockerfile b/16-3.4/Dockerfile similarity index 90% rename from 16rc1-3.4/Dockerfile rename to 16-3.4/Dockerfile index 1fabe68c..0d16c535 100644 --- a/16rc1-3.4/Dockerfile +++ b/16-3.4/Dockerfile @@ -2,10 +2,10 @@ # NOTE: THIS DOCKERFILE IS GENERATED VIA "make update"! PLEASE DO NOT EDIT IT DIRECTLY. # -FROM postgres:16rc1-bullseye +FROM postgres:16-bullseye LABEL maintainer="PostGIS Project - https://postgis.net" \ - org.opencontainers.image.description="PostGIS 3.4.0+dfsg-1.pgdg110+1 spatial database extension with PostgreSQL 16rc1 bullseye" \ + org.opencontainers.image.description="PostGIS 3.4.0+dfsg-1.pgdg110+1 spatial database extension with PostgreSQL 16 bullseye" \ org.opencontainers.image.source="https://github.com/postgis/docker-postgis" ENV POSTGIS_MAJOR 3 diff --git a/16rc1-3.4/alpine/Dockerfile b/16-3.4/alpine/Dockerfile similarity index 98% rename from 16rc1-3.4/alpine/Dockerfile rename to 16-3.4/alpine/Dockerfile index 997f72a1..5fb7cc3c 100644 --- a/16rc1-3.4/alpine/Dockerfile +++ b/16-3.4/alpine/Dockerfile @@ -1,11 +1,11 @@ # # NOTE: THIS DOCKERFILE IS GENERATED VIA "make update"! PLEASE DO NOT EDIT IT DIRECTLY. # -ARG BASE_IMAGE=postgres:16rc1-alpine3.18 +ARG BASE_IMAGE=postgres:16-alpine3.18 FROM ${BASE_IMAGE} LABEL maintainer="PostGIS Project - https://postgis.net" \ - org.opencontainers.image.description="PostGIS 3.4.0 spatial database extension with PostgreSQL 16rc1 Alpine" \ + org.opencontainers.image.description="PostGIS 3.4.0 spatial database extension with PostgreSQL 16 Alpine" \ org.opencontainers.image.source="https://github.com/postgis/docker-postgis" ENV POSTGIS_VERSION 3.4.0 diff --git a/14-master/initdb-postgis.sh b/16-3.4/alpine/initdb-postgis.sh similarity index 100% rename from 14-master/initdb-postgis.sh rename to 16-3.4/alpine/initdb-postgis.sh diff --git a/14-master/update-postgis.sh b/16-3.4/alpine/update-postgis.sh similarity index 100% rename from 14-master/update-postgis.sh rename to 16-3.4/alpine/update-postgis.sh diff --git a/16rc1-3.4/alpine/initdb-postgis.sh b/16-3.4/initdb-postgis.sh similarity index 100% rename from 16rc1-3.4/alpine/initdb-postgis.sh rename to 16-3.4/initdb-postgis.sh diff --git a/16rc1-3.4/alpine/update-postgis.sh b/16-3.4/update-postgis.sh similarity index 100% rename from 16rc1-3.4/alpine/update-postgis.sh rename to 16-3.4/update-postgis.sh diff --git a/14-master/Dockerfile b/16-master/Dockerfile similarity index 94% rename from 14-master/Dockerfile rename to 16-master/Dockerfile index ff3d515d..2c2efae4 100644 --- a/14-master/Dockerfile +++ b/16-master/Dockerfile @@ -7,10 +7,10 @@ ARG DOCKER_CMAKE_BUILD_TYPE=Release ARG CGAL_GIT_BRANCH=5.6.x-branch -FROM postgres:14-bullseye as builder +FROM postgres:16-bullseye as builder LABEL maintainer="PostGIS Project - https://postgis.net" \ - org.opencontainers.image.description="PostGIS - master spatial database extension with PostgreSQL 14 bullseye" \ + org.opencontainers.image.description="PostGIS - master spatial database extension with PostgreSQL 16 bullseye" \ org.opencontainers.image.source="https://github.com/postgis/docker-postgis" WORKDIR / @@ -88,7 +88,7 @@ ENV DOCKER_CMAKE_BUILD_TYPE=${DOCKER_CMAKE_BUILD_TYPE} # one can benefit from the latest CGAL patches while avoiding compatibility issues. ARG CGAL_GIT_BRANCH ENV CGAL_GIT_BRANCH=${CGAL_GIT_BRANCH} -ENV CGAL5X_GIT_HASH 9c9a2690fb4916c249342f3c2dcd08ccd99b7ac8 +ENV CGAL5X_GIT_HASH 3c8e2053721271119499506ea1d8a49dee89e30c ENV SFCGAL_GIT_HASH fc4dc5640e402c8b00426b5a3562324226725df9 RUN set -ex \ && mkdir -p /usr/src \ @@ -122,7 +122,7 @@ RUN set -ex \ && rm -fr /usr/src/cgal # proj -ENV PROJ_GIT_HASH 4a14240a606e5d2ba091a922f52cd3f38dba258c +ENV PROJ_GIT_HASH d4ebd920c1e1ecd0e192790ab4fdb98c7b982176 RUN set -ex \ && cd /usr/src \ && git clone https://github.com/OSGeo/PROJ.git \ @@ -152,7 +152,7 @@ RUN set -ex \ && rm -fr /usr/src/PROJ # geos -ENV GEOS_GIT_HASH 15185e65b3e7bc671cf693c97cf103125fb4a171 +ENV GEOS_GIT_HASH 1033161eca3684e0d9479daeafd35a4e0fb1800e RUN set -ex \ && cd /usr/src \ && git clone https://github.com/libgeos/geos.git \ @@ -168,7 +168,7 @@ RUN set -ex \ && rm -fr /usr/src/geos # gdal -ENV GDAL_GIT_HASH 7dec7e98b6be558ef76e1c17262994610a532573 +ENV GDAL_GIT_HASH 43e51bc48e7d48795ae60731ddc1414611ec5d3e RUN set -ex \ && cd /usr/src \ && git clone https://github.com/OSGeo/gdal.git \ @@ -252,7 +252,7 @@ RUN set -ex \ # ------------------------------------------- # STAGE final # ------------------------------------------- -FROM postgres:14-bullseye +FROM postgres:16-bullseye ARG DOCKER_CMAKE_BUILD_TYPE ENV DOCKER_CMAKE_BUILD_TYPE=${DOCKER_CMAKE_BUILD_TYPE} @@ -301,11 +301,11 @@ COPY --from=builder /usr/local /usr/local ARG CGAL_GIT_BRANCH ENV CGAL_GIT_BRANCH=${CGAL_GIT_BRANCH} -ENV CGAL5X_GIT_HASH 9c9a2690fb4916c249342f3c2dcd08ccd99b7ac8 +ENV CGAL5X_GIT_HASH 3c8e2053721271119499506ea1d8a49dee89e30c ENV SFCGAL_GIT_HASH fc4dc5640e402c8b00426b5a3562324226725df9 -ENV PROJ_GIT_HASH 4a14240a606e5d2ba091a922f52cd3f38dba258c -ENV GEOS_GIT_HASH 15185e65b3e7bc671cf693c97cf103125fb4a171 -ENV GDAL_GIT_HASH 7dec7e98b6be558ef76e1c17262994610a532573 +ENV PROJ_GIT_HASH d4ebd920c1e1ecd0e192790ab4fdb98c7b982176 +ENV GEOS_GIT_HASH 1033161eca3684e0d9479daeafd35a4e0fb1800e +ENV GDAL_GIT_HASH 43e51bc48e7d48795ae60731ddc1414611ec5d3e # Minimal command line test ( fail fast ) RUN set -ex \ @@ -324,7 +324,7 @@ RUN set -ex \ || echo "ogr2ogr missing PostgreSQL driver" && exit 1 # install postgis -ENV POSTGIS_GIT_HASH cc7a8ca0871ae2114e920aa7472c639ec80abe7d +ENV POSTGIS_GIT_HASH d7b58458ea7cf8157d09f59e955820d3a4321892 RUN set -ex \ && apt-get update \ @@ -336,6 +336,8 @@ RUN set -ex \ build-essential \ ca-certificates \ cmake \ + docbook-xml \ + docbook5-xml \ g++ \ git \ libboost-all-dev \ @@ -350,6 +352,7 @@ RUN set -ex \ libtiff-dev \ libtool \ libxml2-dev \ + libxml2-utils \ make \ pkg-config \ postgresql-server-dev-$PG_MAJOR \ @@ -409,6 +412,8 @@ RUN set -ex \ bison \ build-essential \ cmake \ + docbook-xml \ + docbook5-xml \ g++ \ git \ libboost-all-dev \ @@ -422,6 +427,7 @@ RUN set -ex \ libtiff-dev \ libtool \ libxml2-dev \ + libxml2-utils \ make \ pkg-config \ postgresql-server-dev-$PG_MAJOR \ diff --git a/16rc1-3.4/initdb-postgis.sh b/16-master/initdb-postgis.sh similarity index 100% rename from 16rc1-3.4/initdb-postgis.sh rename to 16-master/initdb-postgis.sh diff --git a/16rc1-3.4/update-postgis.sh b/16-master/update-postgis.sh similarity index 100% rename from 16rc1-3.4/update-postgis.sh rename to 16-master/update-postgis.sh diff --git a/16rc1-master/Dockerfile b/16rc1-master/Dockerfile deleted file mode 100644 index 0410de97..00000000 --- a/16rc1-master/Dockerfile +++ /dev/null @@ -1,456 +0,0 @@ -# -# NOTE: THIS DOCKERFILE IS GENERATED VIA "make update"! PLEASE DO NOT EDIT IT DIRECTLY. -# - -# "Experimental"; solely for testing purposes. Anticipate frequent changes! -# This is a multi-stage Dockerfile, requiring a minimum Docker version of 17.05. - -ARG DOCKER_CMAKE_BUILD_TYPE=Release -ARG CGAL_GIT_BRANCH=5.6.x-branch -FROM postgres:16rc1-bullseye as builder - -LABEL maintainer="PostGIS Project - https://postgis.net" \ - org.opencontainers.image.description="PostGIS - master spatial database extension with PostgreSQL 16rc1 bullseye" \ - org.opencontainers.image.source="https://github.com/postgis/docker-postgis" - -WORKDIR / - -# apt-get install -RUN set -ex \ - && apt-get update \ - && apt-get install -y --no-install-recommends \ - curl \ - libboost-atomic1.74.0 \ - libboost-chrono1.74.0 \ - libboost-date-time1.74.0 \ - libboost-filesystem1.74.0 \ - libboost-program-options1.74.0 \ - libboost-serialization1.74.0 \ - libboost-system1.74.0 \ - libboost-test1.74.0 \ - libboost-thread1.74.0 \ - libboost-timer1.74.0 \ - libcurl3-gnutls \ - libexpat1 \ - libgmp10 \ - libgmpxx4ldbl \ - libjson-c5 \ - libmpfr6 \ - libprotobuf-c1 \ - libtiff5 \ - libxml2 \ - sqlite3 \ - # build dependency - autoconf \ - automake \ - autotools-dev \ - bison \ - build-essential \ - ca-certificates \ - cmake \ - g++ \ - git \ - libboost-all-dev \ - libcurl4-gnutls-dev \ - libgmp-dev \ - libjson-c-dev \ - libmpfr-dev \ - libpcre3-dev \ - libpq-dev \ - libprotobuf-c-dev \ - libsqlite3-dev \ - libtiff-dev \ - libtool \ - libxml2-dev \ - make \ - pkg-config \ - protobuf-c-compiler \ - xsltproc \ - # gdal+ - libblosc-dev \ - libcfitsio-dev \ - libfreexl-dev \ - libfyba-dev \ - libhdf5-dev \ - libkml-dev \ - liblz4-dev \ - liblzma-dev \ - libopenjp2-7-dev \ - libqhull-dev \ - libwebp-dev \ - libzstd-dev - -ARG DOCKER_CMAKE_BUILD_TYPE -ENV DOCKER_CMAKE_BUILD_TYPE=${DOCKER_CMAKE_BUILD_TYPE} - -# cgal & sfcgal -# By utilizing the latest commit of the CGAL 5.x.x-branch and implementing a header-only build for SFCGAL, -# one can benefit from the latest CGAL patches while avoiding compatibility issues. -ARG CGAL_GIT_BRANCH -ENV CGAL_GIT_BRANCH=${CGAL_GIT_BRANCH} -ENV CGAL5X_GIT_HASH 9c9a2690fb4916c249342f3c2dcd08ccd99b7ac8 -ENV SFCGAL_GIT_HASH fc4dc5640e402c8b00426b5a3562324226725df9 -RUN set -ex \ - && mkdir -p /usr/src \ - && cd /usr/src \ - && git clone --branch ${CGAL_GIT_BRANCH} https://github.com/CGAL/cgal \ - && cd cgal \ - && git checkout ${CGAL5X_GIT_HASH} \ - && git log -1 > /_pgis_cgal_last_commit.txt \ - && cd /usr/src \ - && git clone https://gitlab.com/Oslandia/SFCGAL.git \ - && cd SFCGAL \ - && git checkout ${SFCGAL_GIT_HASH} \ - && git log -1 > /_pgis_sfcgal_last_commit.txt \ - && mkdir cmake-build \ - && cd cmake-build \ - && cmake .. \ - -DCGAL_DIR=/usr/src/cgal \ - -DCMAKE_BUILD_TYPE=${DOCKER_CMAKE_BUILD_TYPE} \ - -DSFCGAL_BUILD_BENCH=OFF \ - -DSFCGAL_BUILD_EXAMPLES=OFF \ - -DSFCGAL_BUILD_TESTS=OFF \ - -DSFCGAL_WITH_OSG=OFF \ - && make -j$(nproc) \ - && make install \ - # - ## testing with -DSFCGAL_BUILD_TESTS=ON - # && CTEST_OUTPUT_ON_FAILURE=TRUE ctest \ - # - # clean - && rm -fr /usr/src/SFCGAL \ - && rm -fr /usr/src/cgal - -# proj -ENV PROJ_GIT_HASH 4a14240a606e5d2ba091a922f52cd3f38dba258c -RUN set -ex \ - && cd /usr/src \ - && git clone https://github.com/OSGeo/PROJ.git \ - && cd PROJ \ - && git checkout ${PROJ_GIT_HASH} \ - && git log -1 > /_pgis_proj_last_commit.txt \ - # check the autotools exist? https://github.com/OSGeo/PROJ/pull/3027 - && if [ -f "autogen.sh" ] ; then \ - set -eux \ - && echo "autotools version: 'autogen.sh' exists! Older version!" \ - && ./autogen.sh \ - && ./configure --disable-static \ - && make -j$(nproc) \ - && make install \ - ; \ - else \ - set -eux \ - && echo "cmake version: 'autogen.sh' does not exists! Newer version!" \ - && mkdir build \ - && cd build \ - && cmake .. -DCMAKE_BUILD_TYPE=${DOCKER_CMAKE_BUILD_TYPE} -DBUILD_TESTING=OFF \ - && make -j$(nproc) \ - && make install \ - ; \ - fi \ - \ - && rm -fr /usr/src/PROJ - -# geos -ENV GEOS_GIT_HASH 15185e65b3e7bc671cf693c97cf103125fb4a171 -RUN set -ex \ - && cd /usr/src \ - && git clone https://github.com/libgeos/geos.git \ - && cd geos \ - && git checkout ${GEOS_GIT_HASH} \ - && git log -1 > /_pgis_geos_last_commit.txt \ - && mkdir cmake-build \ - && cd cmake-build \ - && cmake .. -DCMAKE_BUILD_TYPE=${DOCKER_CMAKE_BUILD_TYPE} -DBUILD_TESTING=OFF \ - && make -j$(nproc) \ - && make install \ - && cd / \ - && rm -fr /usr/src/geos - -# gdal -ENV GDAL_GIT_HASH 7dec7e98b6be558ef76e1c17262994610a532573 -RUN set -ex \ - && cd /usr/src \ - && git clone https://github.com/OSGeo/gdal.git \ - && cd gdal \ - && git checkout ${GDAL_GIT_HASH} \ - && git log -1 > /_pgis_gdal_last_commit.txt \ - \ - # gdal project directory structure - has been changed ! - && if [ -d "gdal" ] ; then \ - echo "Directory 'gdal' dir exists -> older version!" ; \ - cd gdal ; \ - else \ - echo "Directory 'gdal' does not exists! Newer version! " ; \ - fi \ - \ - && if [ -f "./autogen.sh" ]; then \ - # Building with autoconf ( old/deprecated ) - set -eux \ - && ./autogen.sh \ - && ./configure --disable-static \ - ; \ - else \ - # Building with cmake - set -eux \ - && mkdir build \ - && cd build \ - # config based on: https://salsa.debian.org/debian-gis-team/gdal/-/blob/master/debian/rules - && cmake .. -DCMAKE_BUILD_TYPE=${DOCKER_CMAKE_BUILD_TYPE} -DBUILD_TESTING=OFF \ - -DBUILD_DOCS=OFF \ - \ - -DGDAL_HIDE_INTERNAL_SYMBOLS=ON \ - -DRENAME_INTERNAL_TIFF_SYMBOLS=ON \ - -DGDAL_USE_BLOSC=ON \ - -DGDAL_USE_CFITSIO=ON \ - -DGDAL_USE_CURL=ON \ - -DGDAL_USE_DEFLATE=ON \ - -DGDAL_USE_EXPAT=ON \ - -DGDAL_USE_FREEXL=ON \ - -DGDAL_USE_FYBA=ON \ - -DGDAL_USE_GEOS=ON \ - -DGDAL_USE_HDF5=ON \ - -DGDAL_USE_JSONC=ON \ - -DGDAL_USE_LERC_INTERNAL=ON \ - -DGDAL_USE_LIBKML=ON \ - -DGDAL_USE_LIBLZMA=ON \ - -DGDAL_USE_LZ4=ON \ - -DGDAL_USE_OPENJPEG=ON \ - -DGDAL_USE_POSTGRESQL=ON \ - -DGDAL_USE_QHULL=ON \ - -DGDAL_USE_SQLITE3=ON \ - -DGDAL_USE_TIFF=ON \ - -DGDAL_USE_WEBP=ON \ - -DGDAL_USE_ZSTD=ON \ - \ - # OFF and Not working https://github.com/OSGeo/gdal/issues/7100 - # -DRENAME_INTERNAL_GEOTIFF_SYMBOLS=ON \ - -DGDAL_USE_ECW=OFF \ - -DGDAL_USE_GEOTIFF=OFF \ - -DGDAL_USE_HEIF=OFF \ - -DGDAL_USE_SPATIALITE=OFF \ - ; \ - fi \ - \ - && make -j$(nproc) \ - && make install \ - && cd / \ - && rm -fr /usr/src/gdal - -# Minimal command line test. -RUN set -ex \ - && ldconfig \ - && cs2cs \ - && ldd $(which gdalinfo) \ - && gdalinfo --version \ - && geos-config --version \ - && ogr2ogr --version \ - && proj \ - && sfcgal-config --version \ - && pcre-config --version - -# ------------------------------------------- -# STAGE final -# ------------------------------------------- -FROM postgres:16rc1-bullseye - -ARG DOCKER_CMAKE_BUILD_TYPE -ENV DOCKER_CMAKE_BUILD_TYPE=${DOCKER_CMAKE_BUILD_TYPE} - -RUN set -ex \ - && apt-get update \ - && apt-get install -y --no-install-recommends \ - curl \ - libboost-atomic1.74.0 \ - libboost-chrono1.74.0 \ - libboost-date-time1.74.0 \ - libboost-filesystem1.74.0 \ - libboost-program-options1.74.0 \ - libboost-serialization1.74.0 \ - libboost-system1.74.0 \ - libboost-test1.74.0 \ - libboost-thread1.74.0 \ - libboost-timer1.74.0 \ - libcurl3-gnutls \ - libexpat1 \ - libgmp10 \ - libgmpxx4ldbl \ - libjson-c5 \ - libmpfr6 \ - libpcre3 \ - libprotobuf-c1 \ - libtiff5 \ - libxml2 \ - sqlite3 \ - # gdal+ - libblosc1 \ - libcfitsio9 \ - libfreexl1 \ - libfyba0 \ - libhdf5-103-1 \ - libkmlbase1 \ - libkmldom1 \ - libkmlengine1 \ - libopenjp2-7 \ - libqhull-r8.0 \ - && apt-get clean \ - && rm -rf /var/lib/apt/lists/* - -COPY --from=builder /_pgis*.* / -COPY --from=builder /usr/local /usr/local - -ARG CGAL_GIT_BRANCH -ENV CGAL_GIT_BRANCH=${CGAL_GIT_BRANCH} -ENV CGAL5X_GIT_HASH 9c9a2690fb4916c249342f3c2dcd08ccd99b7ac8 -ENV SFCGAL_GIT_HASH fc4dc5640e402c8b00426b5a3562324226725df9 -ENV PROJ_GIT_HASH 4a14240a606e5d2ba091a922f52cd3f38dba258c -ENV GEOS_GIT_HASH 15185e65b3e7bc671cf693c97cf103125fb4a171 -ENV GDAL_GIT_HASH 7dec7e98b6be558ef76e1c17262994610a532573 - -# Minimal command line test ( fail fast ) -RUN set -ex \ - && ldconfig \ - && cs2cs \ - && ldd $(which gdalinfo) \ - && gdalinfo --version \ - && gdal-config --formats \ - && geos-config --version \ - && ogr2ogr --version \ - && proj \ - && sfcgal-config --version \ - \ - # Testing ogr2ogr PostgreSQL driver. - && ogr2ogr --formats | grep -q "PostgreSQL/PostGIS" && exit 0 \ - || echo "ogr2ogr missing PostgreSQL driver" && exit 1 - -# install postgis -ENV POSTGIS_GIT_HASH cc7a8ca0871ae2114e920aa7472c639ec80abe7d - -RUN set -ex \ - && apt-get update \ - && apt-get install -y --no-install-recommends \ - autoconf \ - automake \ - autotools-dev \ - bison \ - build-essential \ - ca-certificates \ - cmake \ - g++ \ - git \ - libboost-all-dev \ - libcunit1-dev \ - libcurl4-gnutls-dev \ - libgmp-dev \ - libjson-c-dev \ - libmpfr-dev \ - libpcre3-dev \ - libprotobuf-c-dev \ - libsqlite3-dev \ - libtiff-dev \ - libtool \ - libxml2-dev \ - make \ - pkg-config \ - postgresql-server-dev-$PG_MAJOR \ - protobuf-c-compiler \ - xsltproc \ - && cd \ - # postgis - && cd /usr/src/ \ - && git clone https://github.com/postgis/postgis.git \ - && cd postgis \ - && git checkout ${POSTGIS_GIT_HASH} \ - && git log -1 > /_pgis_last_commit.txt \ - && ./autogen.sh \ -# configure options taken from: -# https://anonscm.debian.org/cgit/pkg-grass/postgis.git/tree/debian/rules?h=jessie - && ./configure \ - --enable-lto \ - && make -j$(nproc) \ - && make install \ -# refresh proj data - workarounds: https://trac.osgeo.org/postgis/ticket/5316 - && projsync --system-directory --file ch_swisstopo_CHENyx06_ETRS \ - && projsync --system-directory --file us_noaa_eshpgn \ - && projsync --system-directory --file us_noaa_prvi \ - && projsync --system-directory --file us_noaa_wmhpgn \ -# regress check - && mkdir /tempdb \ - && chown -R postgres:postgres /tempdb \ - && su postgres -c 'pg_ctl -D /tempdb init' \ - && su postgres -c 'pg_ctl -D /tempdb -c -l /tmp/logfile -o '-F' start ' \ - && ldconfig \ - && cd regress \ - && make -j$(nproc) check RUNTESTFLAGS=--extension PGUSER=postgres \ - \ - && su postgres -c 'psql -c "CREATE EXTENSION IF NOT EXISTS postgis;"' \ - && su postgres -c 'psql -c "CREATE EXTENSION IF NOT EXISTS postgis_raster;"' \ - && su postgres -c 'psql -c "CREATE EXTENSION IF NOT EXISTS postgis_sfcgal;"' \ - && su postgres -c 'psql -c "CREATE EXTENSION IF NOT EXISTS fuzzystrmatch; --needed for postgis_tiger_geocoder "' \ - && su postgres -c 'psql -c "CREATE EXTENSION IF NOT EXISTS address_standardizer;"' \ - && su postgres -c 'psql -c "CREATE EXTENSION IF NOT EXISTS address_standardizer_data_us;"' \ - && su postgres -c 'psql -c "CREATE EXTENSION IF NOT EXISTS postgis_tiger_geocoder;"' \ - && su postgres -c 'psql -c "CREATE EXTENSION IF NOT EXISTS postgis_topology;"' \ - && su postgres -c 'psql -t -c "SELECT version();"' >> /_pgis_full_version.txt \ - && su postgres -c 'psql -t -c "SELECT PostGIS_Full_Version();"' >> /_pgis_full_version.txt \ - && su postgres -c 'psql -t -c "\dx"' >> /_pgis_full_version.txt \ - \ - && su postgres -c 'pg_ctl -D /tempdb --mode=immediate stop' \ - && rm -rf /tempdb \ - && rm -rf /tmp/logfile \ - && rm -rf /tmp/pgis_reg \ -# clean - && cd / \ - && rm -rf /usr/src/postgis \ - && apt-get purge -y --autoremove \ - autoconf \ - automake \ - autotools-dev \ - bison \ - build-essential \ - cmake \ - g++ \ - git \ - libboost-all-dev \ - libcurl4-gnutls-dev \ - libgmp-dev \ - libjson-c-dev \ - libmpfr-dev \ - libpcre3-dev \ - libprotobuf-c-dev \ - libsqlite3-dev \ - libtiff-dev \ - libtool \ - libxml2-dev \ - make \ - pkg-config \ - postgresql-server-dev-$PG_MAJOR \ - protobuf-c-compiler \ - xsltproc \ - && apt-get clean \ - && rm -rf /var/lib/apt/lists/* - -RUN mkdir -p /docker-entrypoint-initdb.d -COPY ./initdb-postgis.sh /docker-entrypoint-initdb.d/10_postgis.sh -COPY ./update-postgis.sh /usr/local/bin - -# last final test -RUN set -ex \ - && ldconfig \ - && cs2cs \ - && ldd $(which gdalinfo) \ - && gdalinfo --version \ - && gdal-config --formats \ - && geos-config --version \ - && ogr2ogr --version \ - && proj \ - && sfcgal-config --version \ - \ - # Is the "ca-certificates" package installed? (for accessing remote raster files) - # https://github.com/postgis/docker-postgis/issues/307 - && dpkg-query -W -f='${Status}' ca-certificates 2>/dev/null | grep -c "ok installed" \ - \ - # list last commits. - && find /_pgis_*_last_commit.txt -type f -print -exec cat {} \; \ - # list postgresql, postgis version - && cat _pgis_full_version.txt diff --git a/16rc1-master/initdb-postgis.sh b/16rc1-master/initdb-postgis.sh deleted file mode 100644 index e38ad7d6..00000000 --- a/16rc1-master/initdb-postgis.sh +++ /dev/null @@ -1,25 +0,0 @@ -#!/bin/bash - -set -e - -# Perform all actions as $POSTGRES_USER -export PGUSER="$POSTGRES_USER" - -# Create the 'template_postgis' template db -"${psql[@]}" <<- 'EOSQL' -CREATE DATABASE template_postgis IS_TEMPLATE true; -EOSQL - -# Load PostGIS into both template_database and $POSTGRES_DB -for DB in template_postgis "$POSTGRES_DB"; do - echo "Loading PostGIS extensions into $DB" - "${psql[@]}" --dbname="$DB" <<-'EOSQL' - CREATE EXTENSION IF NOT EXISTS postgis; - CREATE EXTENSION IF NOT EXISTS postgis_topology; - -- Reconnect to update pg_setting.resetval - -- See https://github.com/postgis/docker-postgis/issues/288 - \c - CREATE EXTENSION IF NOT EXISTS fuzzystrmatch; - CREATE EXTENSION IF NOT EXISTS postgis_tiger_geocoder; -EOSQL -done diff --git a/16rc1-master/update-postgis.sh b/16rc1-master/update-postgis.sh deleted file mode 100755 index f98abd26..00000000 --- a/16rc1-master/update-postgis.sh +++ /dev/null @@ -1,28 +0,0 @@ -#!/bin/sh - -set -e - -# Perform all actions as $POSTGRES_USER -export PGUSER="$POSTGRES_USER" - -POSTGIS_VERSION="${POSTGIS_VERSION%%+*}" - -# Load PostGIS into both template_database and $POSTGRES_DB -for DB in template_postgis "$POSTGRES_DB" "${@}"; do - echo "Updating PostGIS extensions '$DB' to $POSTGIS_VERSION" - psql --dbname="$DB" -c " - -- Upgrade PostGIS (includes raster) - CREATE EXTENSION IF NOT EXISTS postgis VERSION '$POSTGIS_VERSION'; - ALTER EXTENSION postgis UPDATE TO '$POSTGIS_VERSION'; - - -- Upgrade Topology - CREATE EXTENSION IF NOT EXISTS postgis_topology VERSION '$POSTGIS_VERSION'; - ALTER EXTENSION postgis_topology UPDATE TO '$POSTGIS_VERSION'; - - -- Install Tiger dependencies in case not already installed - CREATE EXTENSION IF NOT EXISTS fuzzystrmatch; - -- Upgrade US Tiger Geocoder - CREATE EXTENSION IF NOT EXISTS postgis_tiger_geocoder VERSION '$POSTGIS_VERSION'; - ALTER EXTENSION postgis_tiger_geocoder UPDATE TO '$POSTGIS_VERSION'; - " -done diff --git a/Dockerfile.master.template b/Dockerfile.master.template index 04dd33d5..0b78eb15 100644 --- a/Dockerfile.master.template +++ b/Dockerfile.master.template @@ -336,6 +336,8 @@ RUN set -ex \ build-essential \ ca-certificates \ cmake \ + docbook-xml \ + docbook5-xml \ g++ \ git \ libboost-all-dev \ @@ -350,6 +352,7 @@ RUN set -ex \ libtiff-dev \ libtool \ libxml2-dev \ + libxml2-utils \ make \ pkg-config \ postgresql-server-dev-$PG_MAJOR \ @@ -409,6 +412,8 @@ RUN set -ex \ bison \ build-essential \ cmake \ + docbook-xml \ + docbook5-xml \ g++ \ git \ libboost-all-dev \ @@ -422,6 +427,7 @@ RUN set -ex \ libtiff-dev \ libtool \ libxml2-dev \ + libxml2-utils \ make \ pkg-config \ postgresql-server-dev-$PG_MAJOR \ diff --git a/Makefile b/Makefile index eccf40a8..d8e7c674 100644 --- a/Makefile +++ b/Makefile @@ -2,7 +2,7 @@ # When processing the rules for tagging and pushing container images with the # "latest" tag, the following variable will be the version that is considered # to be the latest. -LATEST_VERSION=15-3.4 +LATEST_VERSION=16-3.4 # The following flags are set based on VERSION and VARIANT environment variables # that may have been specified, and are used by rules to determine which diff --git a/README.md b/README.md index f7bda890..7877bc98 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ [![Build Status](https://github.com/postgis/docker-postgis/workflows/Docker%20PostGIS%20CI/badge.svg)](https://github.com/postgis/docker-postgis/actions) [![Join the chat at https://gitter.im/postgis/docker-postgis](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/postgis/docker-postgis?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) -The `postgis/postgis` image provides tags for running Postgres with [PostGIS](http://postgis.net/) extensions installed. This image is based on the official [`postgres`](https://registry.hub.docker.com/_/postgres/) image and provides debian and alpine variants for PostGIS 3.4.x, which is compatible with PostgreSQL versions 12, 13, 14, 15, and 16beta3. For PostgreSQL version 11, the image supports PostGIS 3.3, as it is not compatible with PostGIS 3.4. Additionally, an image version is provided which is built from the latest two versions of Postgres (14, 15) with versions of PostGIS and its dependencies built from their respective master branches. +The `postgis/postgis` image provides tags for running Postgres with [PostGIS](http://postgis.net/) extensions installed. This image is based on the official [`postgres`](https://registry.hub.docker.com/_/postgres/) image and provides debian and alpine variants for PostGIS 3.4.x, which is compatible with PostgreSQL versions 12, 13, 14, 15, and 16. For PostgreSQL version 11, the image supports PostGIS 3.3, as it is not compatible with PostGIS 3.4. Additionally, an image version is provided which is built from the latest two versions of Postgres (15, 16) with versions of PostGIS and its dependencies built from their respective master branches. This image ensures that the default database created by the parent `postgres` image will have the following extensions installed: @@ -18,11 +18,11 @@ This image ensures that the default database created by the parent `postgres` im Unless `-e POSTGRES_DB` is passed to the container at startup time, this database will be named after the admin user (either `postgres` or the user specified with `-e POSTGRES_USER`). If you would prefer to use the older template database mechanism for enabling PostGIS, the image also provides a PostGIS-enabled template database called `template_postgis`. -# Versions (2023-09-01) +# Versions (2023-09-16) Supported architecture: `amd64` (also known as X86-64)" -Recommended version for new users: `postgis/postgis:15-3.4` +Recommended version for new users: `postgis/postgis:16-3.4` ### Debian based (recommended) @@ -41,6 +41,7 @@ Recommended version for new users: `postgis/postgis:15-3.4` | [postgis/postgis:13-3.4](https://registry.hub.docker.com/r/postgis/postgis/tags?page=1&name=13-3.4) | [Dockerfile](https://github.com/postgis/docker-postgis/blob/master/13-3.4/Dockerfile) | debian:bullseye | 13 | 3.4.0 | | [postgis/postgis:14-3.4](https://registry.hub.docker.com/r/postgis/postgis/tags?page=1&name=14-3.4) | [Dockerfile](https://github.com/postgis/docker-postgis/blob/master/14-3.4/Dockerfile) | debian:bullseye | 14 | 3.4.0 | | [postgis/postgis:15-3.4](https://registry.hub.docker.com/r/postgis/postgis/tags?page=1&name=15-3.4) | [Dockerfile](https://github.com/postgis/docker-postgis/blob/master/15-3.4/Dockerfile) | debian:bullseye | 15 | 3.4.0 | +| [postgis/postgis:16-3.4](https://registry.hub.docker.com/r/postgis/postgis/tags?page=1&name=16-3.4) | [Dockerfile](https://github.com/postgis/docker-postgis/blob/master/16-3.4/Dockerfile) | debian:bullseye | 16 | 3.4.0 | ### Alpine based @@ -57,6 +58,7 @@ Recommended version for new users: `postgis/postgis:15-3.4` | [postgis/postgis:13-3.4-alpine](https://registry.hub.docker.com/r/postgis/postgis/tags?page=1&name=13-3.4-alpine) | [Dockerfile](https://github.com/postgis/docker-postgis/blob/master/13-3.4/alpine/Dockerfile) | alpine:3.18 | 13 | 3.4.0 | | [postgis/postgis:14-3.4-alpine](https://registry.hub.docker.com/r/postgis/postgis/tags?page=1&name=14-3.4-alpine) | [Dockerfile](https://github.com/postgis/docker-postgis/blob/master/14-3.4/alpine/Dockerfile) | alpine:3.18 | 14 | 3.4.0 | | [postgis/postgis:15-3.4-alpine](https://registry.hub.docker.com/r/postgis/postgis/tags?page=1&name=15-3.4-alpine) | [Dockerfile](https://github.com/postgis/docker-postgis/blob/master/15-3.4/alpine/Dockerfile) | alpine:3.18 | 15 | 3.4.0 | +| [postgis/postgis:16-3.4-alpine](https://registry.hub.docker.com/r/postgis/postgis/tags?page=1&name=16-3.4-alpine) | [Dockerfile](https://github.com/postgis/docker-postgis/blob/master/16-3.4/alpine/Dockerfile) | alpine:3.18 | 16 | 3.4.0 | ### Test images @@ -66,12 +68,9 @@ Recommended version for new users: `postgis/postgis:15-3.4` | DockerHub image | Dockerfile | OS | Postgres | PostGIS | | --------------- | ---------- | -- | -------- | ------- | -| [postgis/postgis:14-master](https://registry.hub.docker.com/r/postgis/postgis/tags?page=1&name=14-master) | [Dockerfile](https://github.com/postgis/docker-postgis/blob/master/14-master/Dockerfile) | debian:bullseye | 14 | development: postgis, geos, proj, gdal | | [postgis/postgis:15-master](https://registry.hub.docker.com/r/postgis/postgis/tags?page=1&name=15-master) | [Dockerfile](https://github.com/postgis/docker-postgis/blob/master/15-master/Dockerfile) | debian:bullseye | 15 | development: postgis, geos, proj, gdal | -| [postgis/postgis:16rc1-3.4](https://registry.hub.docker.com/r/postgis/postgis/tags?page=1&name=16rc1-3.4) | [Dockerfile](https://github.com/postgis/docker-postgis/blob/master/16rc1-3.4/Dockerfile) | debian:bullseye | 16rc1 | 3.4.0 | -| [postgis/postgis:16rc1-3.4-alpine](https://registry.hub.docker.com/r/postgis/postgis/tags?page=1&name=16rc1-3.4-alpine) | [Dockerfile](https://github.com/postgis/docker-postgis/blob/master/16rc1-3.4/alpine/Dockerfile) | alpine:3.18 | 16rc1 | 3.4.0 | -| [postgis/postgis:16rc1-master](https://registry.hub.docker.com/r/postgis/postgis/tags?page=1&name=16rc1-master) | [Dockerfile](https://github.com/postgis/docker-postgis/blob/master/16rc1-master/Dockerfile) | debian:bullseye | 16rc1 | development: postgis, geos, proj, gdal | - +| [postgis/postgis:16-master](https://registry.hub.docker.com/r/postgis/postgis/tags?page=1&name=16-master) | [Dockerfile](https://github.com/postgis/docker-postgis/blob/master/16-master/Dockerfile) | debian:bullseye | 16 | development: postgis, geos, proj, gdal | + ## Usage In order to run a basic container capable of serving a PostGIS-enabled database, start a container as follows: