From 8a6c52f649827ed490ad01b70e515b3aa0c9f5e1 Mon Sep 17 00:00:00 2001 From: Andrew Kane Date: Wed, 24 Jan 2024 14:18:44 -0800 Subject: [PATCH] Moved Docker image to pgvector org and added tags for each supported version of Postgres [skip ci] --- CHANGELOG.md | 4 +++- Makefile | 10 +++++++--- README.md | 14 +++++++++++++- 3 files changed, 23 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 67fc031..99ea966 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ ## 0.6.0 (unreleased) -If upgrading with Postgres < 13, see [this note](https://github.com/pgvector/pgvector#060). +If upgrading with Postgres 12 or Docker, see [these notes](https://github.com/pgvector/pgvector#060-unreleased). - Changed storage for vector from `extended` to `external` - Improved performance of HNSW @@ -10,6 +10,8 @@ If upgrading with Postgres < 13, see [this note](https://github.com/pgvector/pgv - Reduced WAL generation for HNSW index builds - Fixed error with logical replication - Fixed `invalid memory alloc request size` error with HNSW index build +- Moved Docker image to `pgvector` org +- Added Docker tags for each supported version of Postgres - Dropped support for Postgres 11 ## 0.5.1 (2023-10-10) diff --git a/Makefile b/Makefile index f6c1f20..fe73901 100644 --- a/Makefile +++ b/Makefile @@ -65,13 +65,17 @@ dist: mkdir -p dist git archive --format zip --prefix=$(EXTENSION)-$(EXTVERSION)/ --output dist/$(EXTENSION)-$(EXTVERSION).zip master +# for Docker +PG_MAJOR ?= 16 + .PHONY: docker docker: - docker build --pull --no-cache --platform linux/amd64 -t ankane/pgvector:latest . + docker build --pull --no-cache --build-arg PG_MAJOR=$(PG_MAJOR) -t pgvector/pgvector:pg$(PG_MAJOR) . + docker build --build-arg PG_MAJOR=$(PG_MAJOR) -t pgvector/pgvector:$(EXTVERSION)-pg$(PG_MAJOR) . .PHONY: docker-release docker-release: - docker buildx build --push --pull --no-cache --platform linux/amd64,linux/arm64 -t ankane/pgvector:latest . - docker buildx build --push --platform linux/amd64,linux/arm64 -t ankane/pgvector:v$(EXTVERSION) . + docker buildx build --push --pull --no-cache --platform linux/amd64,linux/arm64 --build-arg PG_MAJOR=$(PG_MAJOR) -t pgvector/pgvector:pg$(PG_MAJOR) . + docker buildx build --push --platform linux/amd64,linux/arm64 --build-arg PG_MAJOR=$(PG_MAJOR) -t pgvector/pgvector:$(EXTVERSION)-pg$(PG_MAJOR) . diff --git a/README.md b/README.md index 7143ce1..cf56d34 100644 --- a/README.md +++ b/README.md @@ -731,7 +731,9 @@ SELECT extversion FROM pg_extension WHERE extname = 'vector'; ### 0.6.0 [unreleased] -If upgrading with Postgres < 13, remove this line from `sql/vector--0.5.1--0.6.0.sql`: +#### Postgres 12 + +If upgrading with Postgres 12, remove this line from `sql/vector--0.5.1--0.6.0.sql`: ```sql ALTER TYPE vector SET (STORAGE = external); @@ -739,6 +741,16 @@ ALTER TYPE vector SET (STORAGE = external); Then run `make install` and `ALTER EXTENSION vector UPDATE;`. +#### Docker + +The Docker image is now published in the `pgvector` org, and there are tags for each supported version of Postgres (rather than a `latest` tag). + +```sh +docker pull pgvector/pgvector:pg16 +# or +docker pull pgvector/pgvector:0.6.0-pg16 +``` + ### 0.4.0 If upgrading with Postgres < 13, remove this line from `sql/vector--0.3.2--0.4.0.sql`: