diff --git a/13-3.5/alpine/Dockerfile b/13-3.5/alpine/Dockerfile index f6ecf8eb1..432551b3c 100644 --- a/13-3.5/alpine/Dockerfile +++ b/13-3.5/alpine/Dockerfile @@ -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 \ @@ -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. @@ -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 \ @@ -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. diff --git a/13-3.5/bullseye/Dockerfile b/13-3.5/bullseye/Dockerfile index e039cee40..3e69bb8bf 100644 --- a/13-3.5/bullseye/Dockerfile +++ b/13-3.5/bullseye/Dockerfile @@ -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 diff --git a/14-3.5/alpine/Dockerfile b/14-3.5/alpine/Dockerfile index 36bebca5c..ff783575f 100644 --- a/14-3.5/alpine/Dockerfile +++ b/14-3.5/alpine/Dockerfile @@ -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 \ @@ -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. @@ -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 \ @@ -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. diff --git a/14-3.5/bullseye/Dockerfile b/14-3.5/bullseye/Dockerfile index 379e3ff05..26ba482c9 100644 --- a/14-3.5/bullseye/Dockerfile +++ b/14-3.5/bullseye/Dockerfile @@ -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 diff --git a/15-3.5/alpine/Dockerfile b/15-3.5/alpine/Dockerfile index 3735b42f5..af38c9ddf 100644 --- a/15-3.5/alpine/Dockerfile +++ b/15-3.5/alpine/Dockerfile @@ -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 \ @@ -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. @@ -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 \ @@ -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. diff --git a/15-3.5/bullseye/Dockerfile b/15-3.5/bullseye/Dockerfile index 4164c0695..b6a831b86 100644 --- a/15-3.5/bullseye/Dockerfile +++ b/15-3.5/bullseye/Dockerfile @@ -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 diff --git a/16-3.5/alpine/Dockerfile b/16-3.5/alpine/Dockerfile index 065c8f023..4d0d7764f 100644 --- a/16-3.5/alpine/Dockerfile +++ b/16-3.5/alpine/Dockerfile @@ -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 \ @@ -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. @@ -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 \ @@ -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. diff --git a/16-3.5/bullseye/Dockerfile b/16-3.5/bullseye/Dockerfile index 77452a0b0..beb8d9e2a 100644 --- a/16-3.5/bullseye/Dockerfile +++ b/16-3.5/bullseye/Dockerfile @@ -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 diff --git a/16-master/bullseye/Dockerfile b/16-master/bullseye/Dockerfile index 551ff7d28..e43cbdcdd 100644 --- a/16-master/bullseye/Dockerfile +++ b/16-master/bullseye/Dockerfile @@ -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 \ @@ -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 \ @@ -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 \ diff --git a/17-3.5/alpine/Dockerfile b/17-3.5/alpine/Dockerfile index 414915b0e..d543e128c 100644 --- a/17-3.5/alpine/Dockerfile +++ b/17-3.5/alpine/Dockerfile @@ -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 \ @@ -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. @@ -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 \ @@ -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. diff --git a/17-3.5/bullseye/Dockerfile b/17-3.5/bullseye/Dockerfile index 9680be9a0..4d811bc85 100644 --- a/17-3.5/bullseye/Dockerfile +++ b/17-3.5/bullseye/Dockerfile @@ -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 diff --git a/17-3.6/alpine/Dockerfile b/17-3.6/alpine/Dockerfile index ad3eed6f2..044c2a8ca 100644 --- a/17-3.6/alpine/Dockerfile +++ b/17-3.6/alpine/Dockerfile @@ -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 \ @@ -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. @@ -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 \ @@ -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. diff --git a/17-master/bullseye/Dockerfile b/17-master/bullseye/Dockerfile index 7e894e84f..a3c4ab3fa 100644 --- a/17-master/bullseye/Dockerfile +++ b/17-master/bullseye/Dockerfile @@ -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 \ @@ -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 \ @@ -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 \ diff --git a/18-3.6/alpine/Dockerfile b/18-3.6/alpine/Dockerfile index 41d6d8c1c..ed7fb0e1d 100644 --- a/18-3.6/alpine/Dockerfile +++ b/18-3.6/alpine/Dockerfile @@ -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 \ @@ -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. @@ -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 \ @@ -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. diff --git a/18-3.6/trixie/Dockerfile b/18-3.6/trixie/Dockerfile index e6a783fed..21834ccde 100644 --- a/18-3.6/trixie/Dockerfile +++ b/18-3.6/trixie/Dockerfile @@ -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 diff --git a/Dockerfile.alpine.template b/Dockerfile.alpine.template index 6f4ee353b..d3eed484e 100644 --- a/Dockerfile.alpine.template +++ b/Dockerfile.alpine.template @@ -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 \ @@ -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. @@ -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 \ @@ -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. diff --git a/Dockerfile.debian.template b/Dockerfile.debian.template index 0871c84e6..df593359b 100644 --- a/Dockerfile.debian.template +++ b/Dockerfile.debian.template @@ -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 diff --git a/Dockerfile.master.template b/Dockerfile.master.template index 1fcde52ce..563961119 100644 --- a/Dockerfile.master.template +++ b/Dockerfile.master.template @@ -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 \ @@ -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 \ @@ -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 \