对 Google 域上托管的域使用自动证书管理失败
Unsuccessful in using Automated Certificate Management for domains hosted on Google Domains
我已经为我的 Ruby Sinatra 应用遵循了 Heroku 的 Automated Certificate Management instructions for generating an SSL certificate via LetsEncrypt(LetsEncrypt 和 heroku 的荣誉!!),但是为我的自定义域生成 SSL 证书失败。
激活自动证书管理后,我的应用程序的 heroku 域名如预期的那样从 *.herokuapp.com 更改为 *.herokudns.com。
我已经相应地更新了我的 Google 域记录,但是 Google 域不允许将域根指定为 CNAME 记录。相反,根需要通过子域转发指向 http(s)://www.mycustomdomain.com,即
mycustomdomain.com --> http://www.mycustomedomain.com
当 heroku 的证书生成过程运行时,它希望同时验证 www.mycustomdomain.com 和 mycustomdomain.com。域根通过子域转发指向 www 地址这一事实似乎阻止了域根的验证。
我猜这会导致生成自定义域 SSL 证书失败?
在查看 heroku 之前,我会联系 Whosebug 社区,以防有人遇到并解决了这个问题?
heroku 上的自定义域设置
user@machine1:~/projects/mycustomdomain$ heroku domains
=== mycustomdomain Heroku Domain
mycustomdomain.herokuapp.com
=== mycustomdomain Custom Domains
Domain Name DNS Target
──────────────── ──────────────────────────────
mycustomdomain.com mycustomdomain.com.herokudns.com
www.mycustomdomain.com www.mycustomdomain.com.herokudns.com
Google 域配置
子域转发
mycustomdomain.com --> http://www.mycustomdomain.com
*.mycustomdomain.com --> http://www.mycustomdomain.com
自定义资源记录
<table style="border:1px solid black; border-collpase">
<tr>
<th>NAME</th>
<th>TYPE</th>
<th>TTL</th>
<th>DATA</th>
</tr>
<tr>
<td>www</td>
<td>CNAME</td>
<td>1h</td>
<td>www.mycustomdomain.com.herokudns.com</td>
</tr>
</table>
作为一个迟来的更新,我发现了以下 link,我已经成功地使用它来配置我在 Google 域上托管的应用程序,以使用 Let's Encrypt SSL:https://medium.com/@connorleech/https-ssl-on-heroku-with-google-domains-as-dns-provider-c55c438556c6
(我提供 link 而不是在这里重述信息,因为信息量很大)
Heroku 已确认:
To use apex domains, we recommend switching to a DNS provider that
support CNAME-like functionality for apex domains, such as Cloudflare,
and then re-enabling ACM.
这记录在他们的网站上:
https://devcenter.heroku.com/articles/custom-domains#configuring-dns-for-root-domains
我已经为我的 Ruby Sinatra 应用遵循了 Heroku 的 Automated Certificate Management instructions for generating an SSL certificate via LetsEncrypt(LetsEncrypt 和 heroku 的荣誉!!),但是为我的自定义域生成 SSL 证书失败。
激活自动证书管理后,我的应用程序的 heroku 域名如预期的那样从 *.herokuapp.com 更改为 *.herokudns.com。
我已经相应地更新了我的 Google 域记录,但是 Google 域不允许将域根指定为 CNAME 记录。相反,根需要通过子域转发指向 http(s)://www.mycustomdomain.com,即
mycustomdomain.com --> http://www.mycustomedomain.com
当 heroku 的证书生成过程运行时,它希望同时验证 www.mycustomdomain.com 和 mycustomdomain.com。域根通过子域转发指向 www 地址这一事实似乎阻止了域根的验证。
我猜这会导致生成自定义域 SSL 证书失败?
在查看 heroku 之前,我会联系 Whosebug 社区,以防有人遇到并解决了这个问题?
heroku 上的自定义域设置
user@machine1:~/projects/mycustomdomain$ heroku domains
=== mycustomdomain Heroku Domain
mycustomdomain.herokuapp.com
=== mycustomdomain Custom Domains
Domain Name DNS Target
──────────────── ──────────────────────────────
mycustomdomain.com mycustomdomain.com.herokudns.com
www.mycustomdomain.com www.mycustomdomain.com.herokudns.com
Google 域配置
子域转发
mycustomdomain.com --> http://www.mycustomdomain.com
*.mycustomdomain.com --> http://www.mycustomdomain.com
自定义资源记录
<table style="border:1px solid black; border-collpase">
<tr>
<th>NAME</th>
<th>TYPE</th>
<th>TTL</th>
<th>DATA</th>
</tr>
<tr>
<td>www</td>
<td>CNAME</td>
<td>1h</td>
<td>www.mycustomdomain.com.herokudns.com</td>
</tr>
</table>
作为一个迟来的更新,我发现了以下 link,我已经成功地使用它来配置我在 Google 域上托管的应用程序,以使用 Let's Encrypt SSL:https://medium.com/@connorleech/https-ssl-on-heroku-with-google-domains-as-dns-provider-c55c438556c6
(我提供 link 而不是在这里重述信息,因为信息量很大)
Heroku 已确认:
To use apex domains, we recommend switching to a DNS provider that support CNAME-like functionality for apex domains, such as Cloudflare, and then re-enabling ACM.
这记录在他们的网站上: https://devcenter.heroku.com/articles/custom-domains#configuring-dns-for-root-domains