Skip to content

Support pgvector pg18 #383

Description

@IlyaSemenov

Currently, pgvector pg18 wouldn't start:

# dokku postgres:create test-pgvector  --image "pgvector/pgvector" --image-version "pg18"
...
       Error: in 18+, these Docker images are configured to store database data in a
              format which is compatible with "pg_ctlcluster" (specifically, using
              major-version-specific directory names).  This better reflects how
              PostgreSQL itself works, and how upgrades are to be performed.
              See also https://github.com/docker-library/postgres/pull/1259
              Counter to that, there appears to be PostgreSQL data in:
                /var/lib/postgresql/data (unused mount/volume)
              This is usually the result of upgrading the Docker image without
              upgrading the underlying database using "pg_upgrade" (which requires both
              versions).
              The suggested container configuration for 18+ is to place a single mount
              at /var/lib/postgresql which will then place PostgreSQL data in a
              subdirectory, allowing usage of "pg_upgrade --link" without mount point
              boundary issues.
              See https://github.com/docker-library/postgres/issues/37 for a (long)
              discussion around this process, and suggestions for how to do so.

I know this was fixed for vanilla Postgres (#365), but apparently pgvector does something differently.

The current workaround I'm using is to add --custom-env "PGDATA=/var/lib/postgresql/data", but I suppose it deserves a proper fix in the plugin.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions