Add insforge pg utils for role privileges
Merged
FE
5mo ago+407+407+012345678901234567890123456789-1-1-0123456789
Allow project_admin to manage RLS policies without being the table owner
Summary by cubic
Adds a PostgreSQL preload utility insforge_pg_utils that lets insforge.policy_grant_role (default project_admin) manage RLS policies on allowlisted tables without being the table owner. Also updates the Postgres image workflow to skip registry login and pushes on pull requests.
-
New Features
- New shared-preload library
insforge_pg_utilswith aProcessUtilityhook. - Supports create/alter/drop/rename policy and enable/disable RLS.
- Runs these statements as the table owner for allowlisted tables.
- Controlled by
insforge.policy_grant_roleandinsforge.policy_grant_tables(comma-separated, schema-qualified).
- New shared-preload library
-
Migration
- Add
insforge_pg_utilstoshared_preload_librariesand restart Postgres. - Set
insforge.policy_grant_role(optional, defaults toproject_admin). - Set
insforge.policy_grant_tableswith the managed tables list. - No
CREATE EXTENSIONneeded; it exposes no SQL objects.
- Add