Why can't my Private Spaces app connect to private Heroku Postgres or Redis instances during deploy?

Issue

You want your app to connect to its private-tier Heroku Postgres or Heroku Redis during deploy and build but the app reports errors like ETIMEDOUT and can not connect to the private datastore.

Resolution

Private Spaces apps are built outside of the Spaces. This makes it impossible to reach the Private datastore protected inside the Private Space while the app is being built and deployed.

If possible, eliminate the dependency on your private datastore during build time or use a datastore in Common Runtime. It maybe possible to make use of Release Phase to run tasks like database migrations on a one-off dyno in the Private Space after the build but before the deploy.

Otherwise, Pipelines maybe of your help:

  1. Create a pipeline and create a Common Runtime app in staging with public datastores
  2. Add the Private Space app in production
  3. Deploy to staging
  4. Promote the staging app to production

Ask on Stack Overflow

Engage with a community of passionate experts to get the answers you need

Ask on Stack Overflow

Heroku Support

Create a support ticket and our support experts will get back to you

Contact Heroku Support
Terms of Service Privacy Cookies © 2018 Salesforce.com