douhezhan5348 2017-11-11 04:24
浏览 122

Heroku Postgres无法从heroku应用程序连接

So I have a go rest api running on Heroku. I had the free tier version but now we have moved the app to production and upgraded to a standard-0 database. None of my code changed the only thing that changed were environmental variables to connect to the database. However, when I try to connect to the database I get this error:

[BRONZE] [5-1] sql_error_code = 28000 FATAL: no pg_hba.conf entry for host "54.234.***.***", user "ub21ndj3*****", database "d8useg2o3****", SSL off

From my understanding its an SSL issue. What I don't understand is my app is running on Heroku servers so I shouldn't need to create a tls config to connect to the database and the same code was working with the previous database. Would there be another issue why I'm getting this error?

  • 写回答

1条回答 默认 最新

  • dpxf81245 2018-10-14 17:23
    关注

    Heroku's standard databases and above require SSL connections as of April, 2016. You can see the Changelog entry here. You were able to use the same application code on a hobby database because they do not have the same restriction.

    评论

报告相同问题?

悬赏问题

  • ¥15 phython如何实现以下功能?查找同一用户名的消费金额合并—
  • ¥15 孟德尔随机化怎样画共定位分析图
  • ¥18 模拟电路问题解答有偿速度
  • ¥15 CST仿真别人的模型结果仿真结果S参数完全不对
  • ¥15 误删注册表文件致win10无法开启
  • ¥15 请问在阿里云服务器中怎么利用数据库制作网站
  • ¥60 ESP32怎么烧录自启动程序
  • ¥50 html2canvas超出滚动条不显示
  • ¥15 java业务性能问题求解(sql,业务设计相关)
  • ¥15 52810 尾椎c三个a 写蓝牙地址