Skip to content
This repository was archived by the owner on Apr 4, 2026. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions 13-3.5/alpine/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ LABEL maintainer="PostGIS Project - https://postgis.net" \

ENV POSTGIS_VERSION=3.5.5
ENV POSTGIS_SHA256=fc3408c474662b5354c9569cfbd18172f2f4818c09945725b8d0089169925fb1
ENV PGVECTOR_VERSION=0.8.0

RUN set -eux \
&& apk add --no-cache --virtual .fetch-deps \
Expand Down Expand Up @@ -67,6 +68,12 @@ RUN set -eux \
&& make -j${NPROC:-$(nproc)} \
&& make install \
\
# build pgvector
&& git clone --branch "v${PGVECTOR_VERSION}" --depth 1 https://github.com/pgvector/pgvector.git /usr/src/pgvector \
&& cd /usr/src/pgvector \
&& make -j${NPROC:-$(nproc)} \
&& make install \
\
# This section is for refreshing the proj data for the regression tests.
# It serves as a workaround for an issue documented at https://trac.osgeo.org/postgis/ticket/5316
# This increases the Docker image size by about 1 MB.
Expand All @@ -90,6 +97,7 @@ RUN set -eux \
&& 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 -c "CREATE EXTENSION IF NOT EXISTS vector;"' \
&& 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 \
Expand Down Expand Up @@ -117,6 +125,7 @@ RUN set -eux \
# clean
&& cd / \
&& rm -rf /usr/src/postgis \
&& rm -rf /usr/src/pgvector \
&& apk del .fetch-deps .build-deps \
# At the end of the build, we print the collected information
# from the '/_pgis_full_version.txt' file. This is for experimental and internal purposes.
Expand Down
1 change: 1 addition & 0 deletions 13-3.5/bullseye/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ RUN apt-get update \
\
postgresql-$PG_MAJOR-postgis-$POSTGIS_MAJOR=$POSTGIS_VERSION \
postgresql-$PG_MAJOR-postgis-$POSTGIS_MAJOR-scripts \
postgresql-$PG_MAJOR-pgvector \
&& rm -rf /var/lib/apt/lists/*

RUN mkdir -p /docker-entrypoint-initdb.d
Expand Down
9 changes: 9 additions & 0 deletions 14-3.5/alpine/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ LABEL maintainer="PostGIS Project - https://postgis.net" \

ENV POSTGIS_VERSION=3.5.5
ENV POSTGIS_SHA256=fc3408c474662b5354c9569cfbd18172f2f4818c09945725b8d0089169925fb1
ENV PGVECTOR_VERSION=0.8.0

RUN set -eux \
&& apk add --no-cache --virtual .fetch-deps \
Expand Down Expand Up @@ -67,6 +68,12 @@ RUN set -eux \
&& make -j${NPROC:-$(nproc)} \
&& make install \
\
# build pgvector
&& git clone --branch "v${PGVECTOR_VERSION}" --depth 1 https://github.com/pgvector/pgvector.git /usr/src/pgvector \
&& cd /usr/src/pgvector \
&& make -j${NPROC:-$(nproc)} \
&& make install \
\
# This section is for refreshing the proj data for the regression tests.
# It serves as a workaround for an issue documented at https://trac.osgeo.org/postgis/ticket/5316
# This increases the Docker image size by about 1 MB.
Expand All @@ -90,6 +97,7 @@ RUN set -eux \
&& 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 -c "CREATE EXTENSION IF NOT EXISTS vector;"' \
&& 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 \
Expand Down Expand Up @@ -117,6 +125,7 @@ RUN set -eux \
# clean
&& cd / \
&& rm -rf /usr/src/postgis \
&& rm -rf /usr/src/pgvector \
&& apk del .fetch-deps .build-deps \
# At the end of the build, we print the collected information
# from the '/_pgis_full_version.txt' file. This is for experimental and internal purposes.
Expand Down
1 change: 1 addition & 0 deletions 14-3.5/bullseye/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ RUN apt-get update \
\
postgresql-$PG_MAJOR-postgis-$POSTGIS_MAJOR=$POSTGIS_VERSION \
postgresql-$PG_MAJOR-postgis-$POSTGIS_MAJOR-scripts \
postgresql-$PG_MAJOR-pgvector \
&& rm -rf /var/lib/apt/lists/*

RUN mkdir -p /docker-entrypoint-initdb.d
Expand Down
9 changes: 9 additions & 0 deletions 15-3.5/alpine/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ LABEL maintainer="PostGIS Project - https://postgis.net" \

ENV POSTGIS_VERSION=3.5.5
ENV POSTGIS_SHA256=fc3408c474662b5354c9569cfbd18172f2f4818c09945725b8d0089169925fb1
ENV PGVECTOR_VERSION=0.8.0

RUN set -eux \
&& apk add --no-cache --virtual .fetch-deps \
Expand Down Expand Up @@ -67,6 +68,12 @@ RUN set -eux \
&& make -j${NPROC:-$(nproc)} \
&& make install \
\
# build pgvector
&& git clone --branch "v${PGVECTOR_VERSION}" --depth 1 https://github.com/pgvector/pgvector.git /usr/src/pgvector \
&& cd /usr/src/pgvector \
&& make -j${NPROC:-$(nproc)} \
&& make install \
\
# This section is for refreshing the proj data for the regression tests.
# It serves as a workaround for an issue documented at https://trac.osgeo.org/postgis/ticket/5316
# This increases the Docker image size by about 1 MB.
Expand All @@ -90,6 +97,7 @@ RUN set -eux \
&& 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 -c "CREATE EXTENSION IF NOT EXISTS vector;"' \
&& 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 \
Expand Down Expand Up @@ -117,6 +125,7 @@ RUN set -eux \
# clean
&& cd / \
&& rm -rf /usr/src/postgis \
&& rm -rf /usr/src/pgvector \
&& apk del .fetch-deps .build-deps \
# At the end of the build, we print the collected information
# from the '/_pgis_full_version.txt' file. This is for experimental and internal purposes.
Expand Down
1 change: 1 addition & 0 deletions 15-3.5/bullseye/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ RUN apt-get update \
\
postgresql-$PG_MAJOR-postgis-$POSTGIS_MAJOR=$POSTGIS_VERSION \
postgresql-$PG_MAJOR-postgis-$POSTGIS_MAJOR-scripts \
postgresql-$PG_MAJOR-pgvector \
&& rm -rf /var/lib/apt/lists/*

RUN mkdir -p /docker-entrypoint-initdb.d
Expand Down
9 changes: 9 additions & 0 deletions 16-3.5/alpine/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ LABEL maintainer="PostGIS Project - https://postgis.net" \

ENV POSTGIS_VERSION=3.5.5
ENV POSTGIS_SHA256=fc3408c474662b5354c9569cfbd18172f2f4818c09945725b8d0089169925fb1
ENV PGVECTOR_VERSION=0.8.0

RUN set -eux \
&& apk add --no-cache --virtual .fetch-deps \
Expand Down Expand Up @@ -67,6 +68,12 @@ RUN set -eux \
&& make -j${NPROC:-$(nproc)} \
&& make install \
\
# build pgvector
&& git clone --branch "v${PGVECTOR_VERSION}" --depth 1 https://github.com/pgvector/pgvector.git /usr/src/pgvector \
&& cd /usr/src/pgvector \
&& make -j${NPROC:-$(nproc)} \
&& make install \
\
# This section is for refreshing the proj data for the regression tests.
# It serves as a workaround for an issue documented at https://trac.osgeo.org/postgis/ticket/5316
# This increases the Docker image size by about 1 MB.
Expand All @@ -90,6 +97,7 @@ RUN set -eux \
&& 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 -c "CREATE EXTENSION IF NOT EXISTS vector;"' \
&& 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 \
Expand Down Expand Up @@ -117,6 +125,7 @@ RUN set -eux \
# clean
&& cd / \
&& rm -rf /usr/src/postgis \
&& rm -rf /usr/src/pgvector \
&& apk del .fetch-deps .build-deps \
# At the end of the build, we print the collected information
# from the '/_pgis_full_version.txt' file. This is for experimental and internal purposes.
Expand Down
1 change: 1 addition & 0 deletions 16-3.5/bullseye/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ RUN apt-get update \
\
postgresql-$PG_MAJOR-postgis-$POSTGIS_MAJOR=$POSTGIS_VERSION \
postgresql-$PG_MAJOR-postgis-$POSTGIS_MAJOR-scripts \
postgresql-$PG_MAJOR-pgvector \
&& rm -rf /var/lib/apt/lists/*

RUN mkdir -p /docker-entrypoint-initdb.d
Expand Down
7 changes: 7 additions & 0 deletions 16-master/bullseye/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -394,6 +394,11 @@ RUN set -ex \
--enable-lto \
&& make -j${NPROC:-$(nproc)} \
&& make install \
# build pgvector
&& git clone --branch v0.8.0 --depth 1 https://github.com/pgvector/pgvector.git /usr/src/pgvector \
&& cd /usr/src/pgvector \
&& make -j${NPROC:-$(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 \
Expand All @@ -416,6 +421,7 @@ RUN set -ex \
&& 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 -c "CREATE EXTENSION IF NOT EXISTS vector;"' \
&& 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 \
Expand All @@ -427,6 +433,7 @@ RUN set -ex \
# clean
&& cd / \
&& rm -rf /usr/src/postgis \
&& rm -rf /usr/src/pgvector \
&& apt-get purge -y --autoremove \
autoconf \
automake \
Expand Down
9 changes: 9 additions & 0 deletions 17-3.5/alpine/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ LABEL maintainer="PostGIS Project - https://postgis.net" \

ENV POSTGIS_VERSION=3.5.5
ENV POSTGIS_SHA256=fc3408c474662b5354c9569cfbd18172f2f4818c09945725b8d0089169925fb1
ENV PGVECTOR_VERSION=0.8.0

RUN set -eux \
&& apk add --no-cache --virtual .fetch-deps \
Expand Down Expand Up @@ -67,6 +68,12 @@ RUN set -eux \
&& make -j${NPROC:-$(nproc)} \
&& make install \
\
# build pgvector
&& git clone --branch "v${PGVECTOR_VERSION}" --depth 1 https://github.com/pgvector/pgvector.git /usr/src/pgvector \
&& cd /usr/src/pgvector \
&& make -j${NPROC:-$(nproc)} \
&& make install \
\
# This section is for refreshing the proj data for the regression tests.
# It serves as a workaround for an issue documented at https://trac.osgeo.org/postgis/ticket/5316
# This increases the Docker image size by about 1 MB.
Expand All @@ -90,6 +97,7 @@ RUN set -eux \
&& 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 -c "CREATE EXTENSION IF NOT EXISTS vector;"' \
&& 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 \
Expand Down Expand Up @@ -117,6 +125,7 @@ RUN set -eux \
# clean
&& cd / \
&& rm -rf /usr/src/postgis \
&& rm -rf /usr/src/pgvector \
&& apk del .fetch-deps .build-deps \
# At the end of the build, we print the collected information
# from the '/_pgis_full_version.txt' file. This is for experimental and internal purposes.
Expand Down
1 change: 1 addition & 0 deletions 17-3.5/bullseye/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ RUN apt-get update \
\
postgresql-$PG_MAJOR-postgis-$POSTGIS_MAJOR=$POSTGIS_VERSION \
postgresql-$PG_MAJOR-postgis-$POSTGIS_MAJOR-scripts \
postgresql-$PG_MAJOR-pgvector \
&& rm -rf /var/lib/apt/lists/*

RUN mkdir -p /docker-entrypoint-initdb.d
Expand Down
9 changes: 9 additions & 0 deletions 17-3.6/alpine/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ LABEL maintainer="PostGIS Project - https://postgis.net" \

ENV POSTGIS_VERSION=3.6.2
ENV POSTGIS_SHA256=607a4d21c017e5283e15d2d977c9b7f575ddfc672afdee81fc84a2d823db4ba5
ENV PGVECTOR_VERSION=0.8.0

RUN set -eux \
&& apk add --no-cache --virtual .fetch-deps \
Expand Down Expand Up @@ -67,6 +68,12 @@ RUN set -eux \
&& make -j${NPROC:-$(nproc)} \
&& make install \
\
# build pgvector
&& git clone --branch "v${PGVECTOR_VERSION}" --depth 1 https://github.com/pgvector/pgvector.git /usr/src/pgvector \
&& cd /usr/src/pgvector \
&& make -j${NPROC:-$(nproc)} \
&& make install \
\
# This section is for refreshing the proj data for the regression tests.
# It serves as a workaround for an issue documented at https://trac.osgeo.org/postgis/ticket/5316
# This increases the Docker image size by about 1 MB.
Expand All @@ -90,6 +97,7 @@ RUN set -eux \
&& 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 -c "CREATE EXTENSION IF NOT EXISTS vector;"' \
&& 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 \
Expand Down Expand Up @@ -117,6 +125,7 @@ RUN set -eux \
# clean
&& cd / \
&& rm -rf /usr/src/postgis \
&& rm -rf /usr/src/pgvector \
&& apk del .fetch-deps .build-deps \
# At the end of the build, we print the collected information
# from the '/_pgis_full_version.txt' file. This is for experimental and internal purposes.
Expand Down
7 changes: 7 additions & 0 deletions 17-master/bullseye/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -394,6 +394,11 @@ RUN set -ex \
--enable-lto \
&& make -j${NPROC:-$(nproc)} \
&& make install \
# build pgvector
&& git clone --branch v0.8.0 --depth 1 https://github.com/pgvector/pgvector.git /usr/src/pgvector \
&& cd /usr/src/pgvector \
&& make -j${NPROC:-$(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 \
Expand All @@ -416,6 +421,7 @@ RUN set -ex \
&& 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 -c "CREATE EXTENSION IF NOT EXISTS vector;"' \
&& 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 \
Expand All @@ -427,6 +433,7 @@ RUN set -ex \
# clean
&& cd / \
&& rm -rf /usr/src/postgis \
&& rm -rf /usr/src/pgvector \
&& apt-get purge -y --autoremove \
autoconf \
automake \
Expand Down
9 changes: 9 additions & 0 deletions 18-3.6/alpine/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ LABEL maintainer="PostGIS Project - https://postgis.net" \

ENV POSTGIS_VERSION=3.6.2
ENV POSTGIS_SHA256=607a4d21c017e5283e15d2d977c9b7f575ddfc672afdee81fc84a2d823db4ba5
ENV PGVECTOR_VERSION=0.8.0

RUN set -eux \
&& apk add --no-cache --virtual .fetch-deps \
Expand Down Expand Up @@ -67,6 +68,12 @@ RUN set -eux \
&& make -j${NPROC:-$(nproc)} \
&& make install \
\
# build pgvector
&& git clone --branch "v${PGVECTOR_VERSION}" --depth 1 https://github.com/pgvector/pgvector.git /usr/src/pgvector \
&& cd /usr/src/pgvector \
&& make -j${NPROC:-$(nproc)} \
&& make install \
\
# This section is for refreshing the proj data for the regression tests.
# It serves as a workaround for an issue documented at https://trac.osgeo.org/postgis/ticket/5316
# This increases the Docker image size by about 1 MB.
Expand All @@ -90,6 +97,7 @@ RUN set -eux \
&& 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 -c "CREATE EXTENSION IF NOT EXISTS vector;"' \
&& 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 \
Expand Down Expand Up @@ -117,6 +125,7 @@ RUN set -eux \
# clean
&& cd / \
&& rm -rf /usr/src/postgis \
&& rm -rf /usr/src/pgvector \
&& apk del .fetch-deps .build-deps \
# At the end of the build, we print the collected information
# from the '/_pgis_full_version.txt' file. This is for experimental and internal purposes.
Expand Down
1 change: 1 addition & 0 deletions 18-3.6/trixie/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ RUN apt-get update \
\
postgresql-$PG_MAJOR-postgis-$POSTGIS_MAJOR=$POSTGIS_VERSION \
postgresql-$PG_MAJOR-postgis-$POSTGIS_MAJOR-scripts \
postgresql-$PG_MAJOR-pgvector \
&& rm -rf /var/lib/apt/lists/*

RUN mkdir -p /docker-entrypoint-initdb.d
Expand Down
9 changes: 9 additions & 0 deletions Dockerfile.alpine.template
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ LABEL maintainer="PostGIS Project - https://postgis.net" \

ENV POSTGIS_VERSION=%%POSTGIS_VERSION%%
ENV POSTGIS_SHA256=%%POSTGIS_SHA256%%
ENV PGVECTOR_VERSION=0.8.0

RUN set -eux \
&& apk add --no-cache --virtual .fetch-deps \
Expand Down Expand Up @@ -67,6 +68,12 @@ RUN set -eux \
&& make -j${NPROC:-$(nproc)} \
&& make install \
\
# build pgvector
&& git clone --branch "v${PGVECTOR_VERSION}" --depth 1 https://github.com/pgvector/pgvector.git /usr/src/pgvector \

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Pin pgvector checkout to an immutable revision

The new git clone --branch "v${PGVECTOR_VERSION}" step fetches pgvector by a mutable tag name rather than an immutable commit, so a tag move or retag upstream can silently change what gets built for the same Dockerfile and produce non-reproducible (or unexpectedly broken) images. This is especially risky here because the template fans out to multiple published variants; prefer cloning a specific commit SHA (and optionally verifying it) to keep builds deterministic.

Useful? React with 👍 / 👎.

&& cd /usr/src/pgvector \
&& make -j${NPROC:-$(nproc)} \
&& make install \
\
# This section is for refreshing the proj data for the regression tests.
# It serves as a workaround for an issue documented at https://trac.osgeo.org/postgis/ticket/5316
# This increases the Docker image size by about 1 MB.
Expand All @@ -90,6 +97,7 @@ RUN set -eux \
&& 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 -c "CREATE EXTENSION IF NOT EXISTS vector;"' \
&& 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 \
Expand Down Expand Up @@ -117,6 +125,7 @@ RUN set -eux \
# clean
&& cd / \
&& rm -rf /usr/src/postgis \
&& rm -rf /usr/src/pgvector \
&& apk del .fetch-deps .build-deps \
# At the end of the build, we print the collected information
# from the '/_pgis_full_version.txt' file. This is for experimental and internal purposes.
Expand Down
Loading
Loading