From 671f1f70fa43c802aa4ee697f837dae8e2cfef6e Mon Sep 17 00:00:00 2001 From: Ko Nagase Date: Mon, 6 Jun 2022 18:09:21 +0900 Subject: [PATCH] Fix search_path race by separating commands way --- 10-2.5/alpine/initdb-postgis.sh | 6 +++--- 10-2.5/initdb-postgis.sh | 6 +++--- 10-3.2/alpine/initdb-postgis.sh | 6 +++--- 10-3.2/initdb-postgis.sh | 6 +++--- 11-2.5/alpine/initdb-postgis.sh | 6 +++--- 11-2.5/initdb-postgis.sh | 6 +++--- 11-3.2/alpine/initdb-postgis.sh | 6 +++--- 11-3.2/initdb-postgis.sh | 6 +++--- 12-3.2/alpine/initdb-postgis.sh | 6 +++--- 12-3.2/initdb-postgis.sh | 6 +++--- 13-3.2/alpine/initdb-postgis.sh | 6 +++--- 13-3.2/initdb-postgis.sh | 6 +++--- 13-master/Dockerfile | 14 +++++++------- 13-master/initdb-postgis.sh | 6 +++--- 14-3.2/alpine/initdb-postgis.sh | 6 +++--- 14-3.2/initdb-postgis.sh | 6 +++--- 14-master/Dockerfile | 14 +++++++------- 14-master/initdb-postgis.sh | 6 +++--- 9.6-2.5/alpine/initdb-postgis.sh | 6 +++--- 9.6-2.5/initdb-postgis.sh | 6 +++--- 9.6-3.2/alpine/initdb-postgis.sh | 6 +++--- 9.6-3.2/initdb-postgis.sh | 6 +++--- initdb-postgis.sh | 6 +++--- 23 files changed, 77 insertions(+), 77 deletions(-) diff --git a/10-2.5/alpine/initdb-postgis.sh b/10-2.5/alpine/initdb-postgis.sh index e38ad7d6..27c1f968 100644 --- a/10-2.5/alpine/initdb-postgis.sh +++ b/10-2.5/alpine/initdb-postgis.sh @@ -16,9 +16,9 @@ for DB in template_postgis "$POSTGRES_DB"; do "${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 +EOSQL + + "${psql[@]}" --dbname="$DB" <<-'EOSQL' CREATE EXTENSION IF NOT EXISTS fuzzystrmatch; CREATE EXTENSION IF NOT EXISTS postgis_tiger_geocoder; EOSQL diff --git a/10-2.5/initdb-postgis.sh b/10-2.5/initdb-postgis.sh index e38ad7d6..27c1f968 100644 --- a/10-2.5/initdb-postgis.sh +++ b/10-2.5/initdb-postgis.sh @@ -16,9 +16,9 @@ for DB in template_postgis "$POSTGRES_DB"; do "${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 +EOSQL + + "${psql[@]}" --dbname="$DB" <<-'EOSQL' CREATE EXTENSION IF NOT EXISTS fuzzystrmatch; CREATE EXTENSION IF NOT EXISTS postgis_tiger_geocoder; EOSQL diff --git a/10-3.2/alpine/initdb-postgis.sh b/10-3.2/alpine/initdb-postgis.sh index e38ad7d6..27c1f968 100644 --- a/10-3.2/alpine/initdb-postgis.sh +++ b/10-3.2/alpine/initdb-postgis.sh @@ -16,9 +16,9 @@ for DB in template_postgis "$POSTGRES_DB"; do "${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 +EOSQL + + "${psql[@]}" --dbname="$DB" <<-'EOSQL' CREATE EXTENSION IF NOT EXISTS fuzzystrmatch; CREATE EXTENSION IF NOT EXISTS postgis_tiger_geocoder; EOSQL diff --git a/10-3.2/initdb-postgis.sh b/10-3.2/initdb-postgis.sh index e38ad7d6..27c1f968 100644 --- a/10-3.2/initdb-postgis.sh +++ b/10-3.2/initdb-postgis.sh @@ -16,9 +16,9 @@ for DB in template_postgis "$POSTGRES_DB"; do "${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 +EOSQL + + "${psql[@]}" --dbname="$DB" <<-'EOSQL' CREATE EXTENSION IF NOT EXISTS fuzzystrmatch; CREATE EXTENSION IF NOT EXISTS postgis_tiger_geocoder; EOSQL diff --git a/11-2.5/alpine/initdb-postgis.sh b/11-2.5/alpine/initdb-postgis.sh index e38ad7d6..27c1f968 100644 --- a/11-2.5/alpine/initdb-postgis.sh +++ b/11-2.5/alpine/initdb-postgis.sh @@ -16,9 +16,9 @@ for DB in template_postgis "$POSTGRES_DB"; do "${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 +EOSQL + + "${psql[@]}" --dbname="$DB" <<-'EOSQL' CREATE EXTENSION IF NOT EXISTS fuzzystrmatch; CREATE EXTENSION IF NOT EXISTS postgis_tiger_geocoder; EOSQL diff --git a/11-2.5/initdb-postgis.sh b/11-2.5/initdb-postgis.sh index e38ad7d6..27c1f968 100644 --- a/11-2.5/initdb-postgis.sh +++ b/11-2.5/initdb-postgis.sh @@ -16,9 +16,9 @@ for DB in template_postgis "$POSTGRES_DB"; do "${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 +EOSQL + + "${psql[@]}" --dbname="$DB" <<-'EOSQL' CREATE EXTENSION IF NOT EXISTS fuzzystrmatch; CREATE EXTENSION IF NOT EXISTS postgis_tiger_geocoder; EOSQL diff --git a/11-3.2/alpine/initdb-postgis.sh b/11-3.2/alpine/initdb-postgis.sh index e38ad7d6..27c1f968 100644 --- a/11-3.2/alpine/initdb-postgis.sh +++ b/11-3.2/alpine/initdb-postgis.sh @@ -16,9 +16,9 @@ for DB in template_postgis "$POSTGRES_DB"; do "${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 +EOSQL + + "${psql[@]}" --dbname="$DB" <<-'EOSQL' CREATE EXTENSION IF NOT EXISTS fuzzystrmatch; CREATE EXTENSION IF NOT EXISTS postgis_tiger_geocoder; EOSQL diff --git a/11-3.2/initdb-postgis.sh b/11-3.2/initdb-postgis.sh index e38ad7d6..27c1f968 100644 --- a/11-3.2/initdb-postgis.sh +++ b/11-3.2/initdb-postgis.sh @@ -16,9 +16,9 @@ for DB in template_postgis "$POSTGRES_DB"; do "${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 +EOSQL + + "${psql[@]}" --dbname="$DB" <<-'EOSQL' CREATE EXTENSION IF NOT EXISTS fuzzystrmatch; CREATE EXTENSION IF NOT EXISTS postgis_tiger_geocoder; EOSQL diff --git a/12-3.2/alpine/initdb-postgis.sh b/12-3.2/alpine/initdb-postgis.sh index e38ad7d6..27c1f968 100644 --- a/12-3.2/alpine/initdb-postgis.sh +++ b/12-3.2/alpine/initdb-postgis.sh @@ -16,9 +16,9 @@ for DB in template_postgis "$POSTGRES_DB"; do "${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 +EOSQL + + "${psql[@]}" --dbname="$DB" <<-'EOSQL' CREATE EXTENSION IF NOT EXISTS fuzzystrmatch; CREATE EXTENSION IF NOT EXISTS postgis_tiger_geocoder; EOSQL diff --git a/12-3.2/initdb-postgis.sh b/12-3.2/initdb-postgis.sh index e38ad7d6..27c1f968 100644 --- a/12-3.2/initdb-postgis.sh +++ b/12-3.2/initdb-postgis.sh @@ -16,9 +16,9 @@ for DB in template_postgis "$POSTGRES_DB"; do "${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 +EOSQL + + "${psql[@]}" --dbname="$DB" <<-'EOSQL' CREATE EXTENSION IF NOT EXISTS fuzzystrmatch; CREATE EXTENSION IF NOT EXISTS postgis_tiger_geocoder; EOSQL diff --git a/13-3.2/alpine/initdb-postgis.sh b/13-3.2/alpine/initdb-postgis.sh index e38ad7d6..27c1f968 100644 --- a/13-3.2/alpine/initdb-postgis.sh +++ b/13-3.2/alpine/initdb-postgis.sh @@ -16,9 +16,9 @@ for DB in template_postgis "$POSTGRES_DB"; do "${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 +EOSQL + + "${psql[@]}" --dbname="$DB" <<-'EOSQL' CREATE EXTENSION IF NOT EXISTS fuzzystrmatch; CREATE EXTENSION IF NOT EXISTS postgis_tiger_geocoder; EOSQL diff --git a/13-3.2/initdb-postgis.sh b/13-3.2/initdb-postgis.sh index e38ad7d6..27c1f968 100644 --- a/13-3.2/initdb-postgis.sh +++ b/13-3.2/initdb-postgis.sh @@ -16,9 +16,9 @@ for DB in template_postgis "$POSTGRES_DB"; do "${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 +EOSQL + + "${psql[@]}" --dbname="$DB" <<-'EOSQL' CREATE EXTENSION IF NOT EXISTS fuzzystrmatch; CREATE EXTENSION IF NOT EXISTS postgis_tiger_geocoder; EOSQL diff --git a/13-master/Dockerfile b/13-master/Dockerfile index 3b33c90a..6c22fb01 100644 --- a/13-master/Dockerfile +++ b/13-master/Dockerfile @@ -82,7 +82,7 @@ RUN set -ex \ # proj ENV PROJ_VERSION master -ENV PROJ_GIT_HASH 9f89c7288e44c64ba234a299b1d5528a54d9d61e +ENV PROJ_GIT_HASH c1083644bcf12b3ce360090613f86c7a8520987f RUN set -ex \ && cd /usr/src \ @@ -114,7 +114,7 @@ RUN set -ex \ # geos ENV GEOS_VERSION master -ENV GEOS_GIT_HASH 2a82afc1ac2327966f56bdf35a6d88aaadb81330 +ENV GEOS_GIT_HASH c8bba596e9cdcf8ad55d804bfa9ba6e4394722a1 RUN set -ex \ && cd /usr/src \ @@ -131,7 +131,7 @@ RUN set -ex \ # gdal ENV GDAL_VERSION master -ENV GDAL_GIT_HASH e1f2b40558cb61dc9ecd3de3282da7115c129c4f +ENV GDAL_GIT_HASH 437570ac3e3a3d9a5d65959bebe72f7e7e12ec99 RUN set -ex \ && cd /usr/src \ @@ -197,9 +197,9 @@ RUN set -ex \ COPY --from=builder /usr/local /usr/local #ENV SFCGAL_GIT_HASH 54b78af7b42f0f348f34879616a5da480b8e4974 -ENV PROJ_GIT_HASH 9f89c7288e44c64ba234a299b1d5528a54d9d61e -ENV GEOS_GIT_HASH 2a82afc1ac2327966f56bdf35a6d88aaadb81330 -ENV GDAL_GIT_HASH e1f2b40558cb61dc9ecd3de3282da7115c129c4f +ENV PROJ_GIT_HASH c1083644bcf12b3ce360090613f86c7a8520987f +ENV GEOS_GIT_HASH c8bba596e9cdcf8ad55d804bfa9ba6e4394722a1 +ENV GDAL_GIT_HASH 437570ac3e3a3d9a5d65959bebe72f7e7e12ec99 # Minimal command line test. RUN set -ex \ @@ -217,7 +217,7 @@ RUN ogr2ogr --formats | grep -q "PostgreSQL/PostGIS" && exit 0 \ # install postgis ENV POSTGIS_VERSION master -ENV POSTGIS_GIT_HASH 6febe57e76d2239ea9779c489eff376f3ed76e72 +ENV POSTGIS_GIT_HASH 50f0801edf94b9f99af34bc9fcdd4826ca9ee994 RUN set -ex \ && apt-get update \ diff --git a/13-master/initdb-postgis.sh b/13-master/initdb-postgis.sh index e38ad7d6..27c1f968 100644 --- a/13-master/initdb-postgis.sh +++ b/13-master/initdb-postgis.sh @@ -16,9 +16,9 @@ for DB in template_postgis "$POSTGRES_DB"; do "${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 +EOSQL + + "${psql[@]}" --dbname="$DB" <<-'EOSQL' CREATE EXTENSION IF NOT EXISTS fuzzystrmatch; CREATE EXTENSION IF NOT EXISTS postgis_tiger_geocoder; EOSQL diff --git a/14-3.2/alpine/initdb-postgis.sh b/14-3.2/alpine/initdb-postgis.sh index e38ad7d6..27c1f968 100644 --- a/14-3.2/alpine/initdb-postgis.sh +++ b/14-3.2/alpine/initdb-postgis.sh @@ -16,9 +16,9 @@ for DB in template_postgis "$POSTGRES_DB"; do "${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 +EOSQL + + "${psql[@]}" --dbname="$DB" <<-'EOSQL' CREATE EXTENSION IF NOT EXISTS fuzzystrmatch; CREATE EXTENSION IF NOT EXISTS postgis_tiger_geocoder; EOSQL diff --git a/14-3.2/initdb-postgis.sh b/14-3.2/initdb-postgis.sh index e38ad7d6..27c1f968 100644 --- a/14-3.2/initdb-postgis.sh +++ b/14-3.2/initdb-postgis.sh @@ -16,9 +16,9 @@ for DB in template_postgis "$POSTGRES_DB"; do "${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 +EOSQL + + "${psql[@]}" --dbname="$DB" <<-'EOSQL' CREATE EXTENSION IF NOT EXISTS fuzzystrmatch; CREATE EXTENSION IF NOT EXISTS postgis_tiger_geocoder; EOSQL diff --git a/14-master/Dockerfile b/14-master/Dockerfile index fbeff181..5a7615d6 100644 --- a/14-master/Dockerfile +++ b/14-master/Dockerfile @@ -82,7 +82,7 @@ RUN set -ex \ # proj ENV PROJ_VERSION master -ENV PROJ_GIT_HASH 9f89c7288e44c64ba234a299b1d5528a54d9d61e +ENV PROJ_GIT_HASH c1083644bcf12b3ce360090613f86c7a8520987f RUN set -ex \ && cd /usr/src \ @@ -114,7 +114,7 @@ RUN set -ex \ # geos ENV GEOS_VERSION master -ENV GEOS_GIT_HASH 2a82afc1ac2327966f56bdf35a6d88aaadb81330 +ENV GEOS_GIT_HASH c8bba596e9cdcf8ad55d804bfa9ba6e4394722a1 RUN set -ex \ && cd /usr/src \ @@ -131,7 +131,7 @@ RUN set -ex \ # gdal ENV GDAL_VERSION master -ENV GDAL_GIT_HASH e1f2b40558cb61dc9ecd3de3282da7115c129c4f +ENV GDAL_GIT_HASH 437570ac3e3a3d9a5d65959bebe72f7e7e12ec99 RUN set -ex \ && cd /usr/src \ @@ -197,9 +197,9 @@ RUN set -ex \ COPY --from=builder /usr/local /usr/local #ENV SFCGAL_GIT_HASH 54b78af7b42f0f348f34879616a5da480b8e4974 -ENV PROJ_GIT_HASH 9f89c7288e44c64ba234a299b1d5528a54d9d61e -ENV GEOS_GIT_HASH 2a82afc1ac2327966f56bdf35a6d88aaadb81330 -ENV GDAL_GIT_HASH e1f2b40558cb61dc9ecd3de3282da7115c129c4f +ENV PROJ_GIT_HASH c1083644bcf12b3ce360090613f86c7a8520987f +ENV GEOS_GIT_HASH c8bba596e9cdcf8ad55d804bfa9ba6e4394722a1 +ENV GDAL_GIT_HASH 437570ac3e3a3d9a5d65959bebe72f7e7e12ec99 # Minimal command line test. RUN set -ex \ @@ -217,7 +217,7 @@ RUN ogr2ogr --formats | grep -q "PostgreSQL/PostGIS" && exit 0 \ # install postgis ENV POSTGIS_VERSION master -ENV POSTGIS_GIT_HASH 6febe57e76d2239ea9779c489eff376f3ed76e72 +ENV POSTGIS_GIT_HASH 50f0801edf94b9f99af34bc9fcdd4826ca9ee994 RUN set -ex \ && apt-get update \ diff --git a/14-master/initdb-postgis.sh b/14-master/initdb-postgis.sh index e38ad7d6..27c1f968 100644 --- a/14-master/initdb-postgis.sh +++ b/14-master/initdb-postgis.sh @@ -16,9 +16,9 @@ for DB in template_postgis "$POSTGRES_DB"; do "${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 +EOSQL + + "${psql[@]}" --dbname="$DB" <<-'EOSQL' CREATE EXTENSION IF NOT EXISTS fuzzystrmatch; CREATE EXTENSION IF NOT EXISTS postgis_tiger_geocoder; EOSQL diff --git a/9.6-2.5/alpine/initdb-postgis.sh b/9.6-2.5/alpine/initdb-postgis.sh index e38ad7d6..27c1f968 100644 --- a/9.6-2.5/alpine/initdb-postgis.sh +++ b/9.6-2.5/alpine/initdb-postgis.sh @@ -16,9 +16,9 @@ for DB in template_postgis "$POSTGRES_DB"; do "${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 +EOSQL + + "${psql[@]}" --dbname="$DB" <<-'EOSQL' CREATE EXTENSION IF NOT EXISTS fuzzystrmatch; CREATE EXTENSION IF NOT EXISTS postgis_tiger_geocoder; EOSQL diff --git a/9.6-2.5/initdb-postgis.sh b/9.6-2.5/initdb-postgis.sh index e38ad7d6..27c1f968 100644 --- a/9.6-2.5/initdb-postgis.sh +++ b/9.6-2.5/initdb-postgis.sh @@ -16,9 +16,9 @@ for DB in template_postgis "$POSTGRES_DB"; do "${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 +EOSQL + + "${psql[@]}" --dbname="$DB" <<-'EOSQL' CREATE EXTENSION IF NOT EXISTS fuzzystrmatch; CREATE EXTENSION IF NOT EXISTS postgis_tiger_geocoder; EOSQL diff --git a/9.6-3.2/alpine/initdb-postgis.sh b/9.6-3.2/alpine/initdb-postgis.sh index e38ad7d6..27c1f968 100644 --- a/9.6-3.2/alpine/initdb-postgis.sh +++ b/9.6-3.2/alpine/initdb-postgis.sh @@ -16,9 +16,9 @@ for DB in template_postgis "$POSTGRES_DB"; do "${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 +EOSQL + + "${psql[@]}" --dbname="$DB" <<-'EOSQL' CREATE EXTENSION IF NOT EXISTS fuzzystrmatch; CREATE EXTENSION IF NOT EXISTS postgis_tiger_geocoder; EOSQL diff --git a/9.6-3.2/initdb-postgis.sh b/9.6-3.2/initdb-postgis.sh index e38ad7d6..27c1f968 100644 --- a/9.6-3.2/initdb-postgis.sh +++ b/9.6-3.2/initdb-postgis.sh @@ -16,9 +16,9 @@ for DB in template_postgis "$POSTGRES_DB"; do "${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 +EOSQL + + "${psql[@]}" --dbname="$DB" <<-'EOSQL' CREATE EXTENSION IF NOT EXISTS fuzzystrmatch; CREATE EXTENSION IF NOT EXISTS postgis_tiger_geocoder; EOSQL diff --git a/initdb-postgis.sh b/initdb-postgis.sh index e38ad7d6..27c1f968 100644 --- a/initdb-postgis.sh +++ b/initdb-postgis.sh @@ -16,9 +16,9 @@ for DB in template_postgis "$POSTGRES_DB"; do "${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 +EOSQL + + "${psql[@]}" --dbname="$DB" <<-'EOSQL' CREATE EXTENSION IF NOT EXISTS fuzzystrmatch; CREATE EXTENSION IF NOT EXISTS postgis_tiger_geocoder; EOSQL