[英]Heroku naked domains with DNS & SSL
I've been struggling with the configuration of my DNS app on Heroku.我一直在努力在 Heroku 上配置我的 DNS 应用程序。 Things I want to accomplish:
我想要完成的事情:
www.example.com
and example.com
, both with SSL config (HTTPS) www.example.com
和example.com
,都带有 SSL 配置 (HTTPS)
Things I tried so far ...到目前为止我尝试过的事情......
GoDaddy Settings:
GoDaddy 设置:
CNAME |
别名 | www |
www | example.com.herokudns.com
example.com.herokudns.com
FOWARDING to https://www.example.com
转发到https://www.example.com
However, this setup is working great with HTTP only, but I'm getting a "Your connection is not private" error when I type the https.但是,此设置仅适用于 HTTP,但在键入 https 时出现“您的连接不是私有的”错误。
I checked several tutorials and none address this issue.我检查了几个教程,没有一个解决这个问题。
PS: I'm using the SSL automatically managed from heroku. PS:我正在使用从 heroku 自动管理的 SSL。
SOLVED IT解决了
Getting the naked domain set up with Godaddy easily: Set forwarding to your domain: https://www.my-domain.com .使用 Godaddy 轻松设置裸域:设置转发到您的域: https : //www.my-domain.com 。 This will redirect non www to the correct place.
这会将非 www 重定向到正确的位置。
With that, I don't actually need to add a second domain in heroku (example.com).有了这个,我实际上不需要在 heroku (example.com) 中添加第二个域。
Just keep the www.example.com, turn the SSL on, go to go daddy and redirect.只需保留 www.example.com,打开 SSL,转到爸爸并重定向。 This is working for me so far....
到目前为止,这对我有用......
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.