Run
docker run -p 54280:54280 ghcr.io/hxndrik/pgquery
Open http://localhost:54280. Images are published for amd64 and arm64.
Docker Compose
services:
pgquery:
image: ghcr.io/hxndrik/pgquery
ports:
- "54280:54280"
environment:
RATE_LIMIT_RPM: 120
restart: unless-stopped
Settings
PORT: listen port, default 54280.RATE_LIMIT_RPM: requests per minute per client IP.MAX_QUERY_TIMEOUTandMAX_ROWS: limits per query.DEMO_DATABASE_URL: run a public demo. pgquery seeds a sample database, serves it read-only and resets it daily (DEMO_RESET_INTERVAL). Instances with a demo also refuse private and local addresses.
Security notes
pgquery has no login of its own. Anyone who can reach it can use it to connect to databases they have credentials for. Put it behind your VPN, an authenticating reverse proxy (oauth2-proxy, Authelia, Cloudflare Access) or bind it to localhost.
Source: github.com/Hxndrik/pgquery