Connect Amazon RDS with Heroku?

2019-08-15 02:27发布

问题:

I have created my Amazon RDS in Oregon region. I have to configure this with my Heroku App. I am able to access RDS from my local machine. But this not happens with Heroku. I also don't have liberty to create Security Groups there. I am getting error as

ERROR 2003 (HY000): Can't connect to MySQL server on 'RDS hostname' (111)

something . I won't understand that because by my local machine it was resolving host but not from Heroku.

回答1:

I Found solution myself, you just have to add inbound IP as 0.0.0.0/0 in security group for RDS to available it publicly.