Repository navigation
pgokf v0.1.14
[0.1.14] - 2026-09-04
Complete logical backups, production container packaging, and native
arm64. The one in-database change makes pg_dump actually capture the
catalog; everything else is packaging, deployment, companion, and CI work.
ALTER EXTENSION pgokf UPDATE TO '0.1.14' adds a trigger and the backup
registrations and touches no existing row; a catalog upgraded with it is
identical to a fresh 0.1.14 install.
Fixed
- BM25 search works for non-superuser readers. With
search_backend = bm25, any session that is not the table owner - every production reader -
gotUnsupported query shapefrom pg_search: row-level security wraps
pgokf.conceptsin a security-barrier subquery its custom scan cannot plan.
The hit query now runs throughpgokf.bm25_hits, aSECURITY DEFINER
helper (pinnedsearch_path, execute granted topgokf_readeronly) that
applies the same explicitpgokf.tenantpredicate the policies enforce, so
concept_searchand the hybrid search keep their invoker-rights contract
and the result set is unchanged. Covered by a new in-database test that runs
wherever pg_search is preloaded. pg_dumpnow captures the catalog. PostgreSQL skips the contents of
extension-owned tables unless the extension registers them with
pg_extension_config_dump; pgokf never did, so every archive carried only
theCREATE EXTENSIONstatement and a restore came back empty - despite the
operations guide describing dumps as complete. Everypgokf.*and
pgokf_private.*table and sequence is now registered (discovered from the
extension's dependency graph, so future tables are covered automatically),
and aBEFORE INSERTtrigger on the singletonpgokf_private.configrow
folds the restored policy row into the oneCREATE EXTENSIONseeds instead
of failing on a duplicate key. Registered relations and the trigger are
asserted by new in-database tests, and the image smoke test restores a real
archive.
Added
- Server image with the optional extensions built in. The Docker image
now ships pgvector, pg_cron, and ParadeDB pg_search (each aWITH_*build
argument; pg_search is fetched from its pinned upstream release and verified
against a committed SHA256 table), aHEALTHCHECK, an OCI version label,
and first-init hooks that create the extensions when preloaded, create
least-privilege login roles fromPGOKF_{ADMIN,WRITER,READER}_PASSWORD, and
apply a JSONPGOKF_POLICYthroughpgokf.set_config. It also carries
pgokf-backup(a verifiedpg_dump+ roles-dump tool with retention) and
pgokf-restore(a single-transaction restore that skips the archive entries
an initialized target cannot replay: pg_search's unownedparadedbschema
and, for a differently named database, pg_cron's objects). - Companions image (
Dockerfile.companions):pgokf-ingest,
pgokf-embed, andpgokf-mcpin one non-root image. - Multi-architecture images. CI builds and smoke-tests both images
natively on amd64 and arm64 runners and merges them into one manifest per
tag (ghcr.io/logicocean/pgokf:<version>-pg<major>,
ghcr.io/logicocean/pgokf-companions:<version>), so they run on x86 and
arm64 servers and on Apple Silicon. The.debmatrix gained arm64 legs. - Reference compose deployment (
deploy/compose/, documented in
docs/compose-deployment.md): server, embedding daemon, cron-driven
backups, and optional ingestion and MCP services, all configured from one
.env. pgokf-embed --watch/--interval: the embedder runs as a daemon that
embeds newly registered or refreshed concepts every interval, reconnecting
per pass and surviving transient outages. The loop and its SIGINT/SIGTERM
shutdown live in the newpgokf-companioncrate, shared withpgokf-ingest
(which therefore now also stops cleanly on SIGTERM, i.e.docker stop).- Packaging lint in CI (hadolint, shellcheck,
docker build --check, compose
render), a.dockerignore, and reusable smoke scripts
(packaging/docker/smoke-test.sh,smoke-test-companions.sh).
Changed
- The image's first-init SQL creates
vectorwhenever present andpg_search
/pg_cronwhen preloaded, instead of onlypgokf. - Documentation: new compose deployment guide; packaging, operations, search,
and deployment-topology guides updated for the bundled extensions, the
backup tool, the embedder daemon, and multi-arch publishing.