How to deploy PgBouncer on Aptible
Setting Up PgBouncer
Gather Database Variables
Create your PgBouncer Application
pgbouncer.crt
and pgbouncer.key
.Generate a Certificate and Key for SSL Authentication
openssl
.-subj "/CN=app-$APP_ID.on-aptible.com/C=US/L=San Francisco"
is modifiable — notably, the Common Name, /CN
, should match the TCP endpoint you’ve created for the pgbouncer App.
If you’re using a default endpoint, you can fill in $APP_ID with your Application’s ID.Create the Dockerfile
pgbouncer.key
, and pgbouncer.crt
.Deploy using Git Push
Make an Endpoint for PgBouncer
Celebrate!