为Heroku外部MySQL数据库连接指定SSL [英] Specify SSL for Heroku external MySQL database connection

查看:115
本文介绍了为Heroku外部MySQL数据库连接指定SSL的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我使用Amazon RDS作为我的MySQL数据库,并且我有适当的DATABASE_URL

如何让Heroku在连接到Amazon RDS时使用SSL?



通常这会在database.yml中被指定为一个值,但是由于Heroku为我们生成了database.yml,我不知道如何控制这个设置。



感谢!

解决方案

从注入的database.yml(见)部分db URL作为查询参数。

从理论上讲,这应该让你配置它,但是我没有尝试过。

I'm running a Rails 3.2 app on the Cedar stack at Heroku.

I'm using Amazon RDS for my MySQL database, and I have the proper DATABASE_URL setup in the Heroku config vars.

How do I get Heroku to use SSL in its connection to Amazon RDS?

Normally this would be specified as a value in database.yml, but since Heroku generates database.yml for us, I'm not sure how to control this setting.

Thanks!

解决方案

From looking at the injected database.yml (see bottom of http://neilmiddleton.com/sharing-databases-between-heroku-applications/) you can pass in extra configuration as part of the db URL as query params.

In theory, this should let you configure it how you want although I've not tried it.

这篇关于为Heroku外部MySQL数据库连接指定SSL的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆