pgvector instructions for GitHub Actions
First, choose your installation method:
To add to the preinstalled Postgres installation on runner images, add a step to your workflow.
Ubuntu
- name: Install pgvector
run: |
sudo /usr/share/postgresql-common/pgdg/apt.postgresql.org.sh -y
sudo apt-get install postgresql-16-pgvector
Note: Replace 16
with your Postgres server version
Mac
- name: Install pgvector
run: brew install pgvector
See a full example
For a service container, use the pgvector/pgvector:pg17
image instead of postgres
.
services:
postgres:
image: pgvector/pgvector:pg17
env:
POSTGRES_HOST_AUTH_METHOD: trust
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
ports:
- 5432:5432
See a full example
Everyone is encouraged to help improve this project. Here are a few ways you can help:
- Report bugs
- Fix bugs and submit pull requests
- Write, clarify, or fix documentation
- Suggest or add new features