![](/img/trans.png)
[英]AWS: Custom SSL certificate option is disabled in CloudFront, but I created a SSL certificate using AWS Certificate Manager
[英]How to create another cloudfront distribution using same SSL certificates created in certificate manager
在 Aws 證書管理器中,我創建了 SSL 證書並將其添加到 dns。
*.test.example.com
在 Cloudfront 中,我創建了一個具有以下 CNAME 的發行版
dev.test.example.com
然后,我可以成功訪問 dev.test.example.com。
之后,我嘗試使用相同的 SSL 證書使用 CNAME uat.test.example.com 創建另一個發行版
但是發生錯誤並且無法創建分發。
com.amazonaws.services.cloudfront.model.CNAMEAlreadyExistsException: One or more aliases specified for the distribution includes an incorrectly configured DNS record that points to another CloudFront distribution. You must update the DNS record to correct the problem
不要在 DNS 中為 cloudfront 使用通配符 ( *
),僅用於證書。 您應該為每個域名創建一個 CNAME 並將其指向其相應的雲端 url:
dev.test.example.com
CNAME 0123456789.cloudfront.net
uat.test.example.com
CNAME 9876543210.cloudfront.net
擁有*.test.example.com
是完全有效的 DNS,但意味着所有匹配*.test.example.com
的流量(包括您的dev
、 uat
和任何其他未來子域)都將發送到您的 dev cloudfront 分發。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.