vectorsearch

VectorSearch Docker Image Build Guide

This project provides a Dockerfile to build a custom PostgreSQL-based image with extensions for vector search. You can customize the build by adjusting the variables in the Makefile.

Build Instructions

  1. Clone the repository:
git clone <repository_url>
cd codecad-rag/retrieval/docker
  1. To build the Docker image with the default settings:
make build
  1. To customize the build, you can modify the following variables in the Makefile:

    • BUILD_VERSION: The version of the build. Default is 0.3.
    • PG_VERSIONS: The major versions of PostgreSQL to build for. Default is 14 15 16 17.
    • PGVECTOR_BASE_VERSION: The base version of the pgvector extension. Default is 0.8.0.
    • PG_SEARCH_VERSION: The version of the pg_search extension. Default is 0.15.8.
    • PG_VECTORSCALE_VERSION: The version of the pgvectorscale extension. Default is 0.5.1.

    For example, to build with PostgreSQL 15 and a custom build version:

# Edit the Makefile and set:
BUILD_VERSION = 1.0
  1. After modifying the Makefile, you can build the Docker image with:
make build
  1. To clean up the downloaded .deb files:
make clean
  1. To prune the Docker images built by this project:
make prune
  1. To push the built images to Docker Hub:
make push

Makefile Variables

The following variables in the Makefile can be tuned to adjust the build process:

By adjusting these variables, you can customize the Docker image to use different versions of PostgreSQL or the extensions.

For a detailed history of changes, see the CHANGELOG.