PostgreSQL Admin Playbook
Environment Variables
Update
.envwithPGADMIN_EMAIL,PGADMIN_PASSWORD, andPGADMIN_CONFIG_SERVER_MODE=True.Master password support is hardcoded off (
PGADMIN_CONFIG_MASTER_PASSWORD_REQUIRED: "False"indeploy/docker/docker-compose.yml); there is no env var to enable it.Keep
.envout of version control and rotate the secrets periodically.
Restart Admin Stack
# Stop and restart pgAdmin (data is in hybridinference_pgadmin_data volume)
make down
make up
# Or to fully reset pgAdmin (destroys saved connections):
docker compose -f deploy/docker/docker-compose.yml --env-file .env --profile admin down
docker volume rm hybridinference_pgadmin_data
docker compose -f deploy/docker/docker-compose.yml --env-file .env --profile admin up -d
Access pgAdmin Securely
SSH into the host with local port forwarding:
ssh -L 5050:127.0.0.1:5050 <user>@<gateway-host>.Open
http://localhost:5050, sign in with the configured email/password. If a master password is configured, unlock with it; otherwise continue directly.
Register Primary Database
In pgAdmin, right-click
Servers→Register→Server.General tab: name the connection (e.g.,
Primary Postgres).Connection tab:
Host name/address:postgresPort:5432Maintenance database: value ofDB_NAMEUsername: value ofDB_USERPassword: value ofDB_PASSWORD
Save and expand the new server to inspect the database named by
DB_NAME; leave the defaultpostgresdatabase for maintenance tasks only.
Post-Restart Checks
make psto confirm bindings on127.0.0.1.Run a smoke query via pgAdmin (e.g.,
SELECT 1;).Log findings in the ops channel and schedule password rotation reminders.