Question

Can we connect to a PostgreSQL Connection Pool from App Platform?

I have my app & local machine in the trusted sources of the database. I can connect to the database from my local machine but unable to connect to it from the app platform.

Is this something not supported or am I missing something?


Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

Any updates here ? We need this feature urgently and there is no new information since March 9,2022.

Hello, unfortunately using Trusted Sources with App Platform and PostgreSQL connection pools is not supported, however, we are actively working to support that functionality.

Hello, Thanks for using DigitalOcean App Platform. PostgreSQL connection pools are now supported in App Platform using trusted sources.

For example if you connect your DigitalOcean database to an App Platform app as “mydb” component, and that database has a connection pool “mypool”, you can use bindable variables to automatically integrate it into your app as a trusted connection. An example environment variable would be:

${mydb.mypool.DATABASE_URL}

See the documentation.

Hope this helps.