The certificate that is attached to your distribution doesn't cover the alternate domain name (CNAME) that you're trying to add
See original GitHub issue🐛 Bug Report
What is the problem?
Ran into a bunch of issues running https://github.com/aws-samples/aws-cdk-examples/tree/master/typescript/static-site/
Last one being
The certificate that is attached to your distribution doesn’t cover the alternate domain name (CNAME) that you’re trying to add
Reproduction Steps
cdk deploy -c domain=webconverger.com -c subdomain=talks
Verbose Log
https://s.natalian.org/2019-08-14/cdk.txt
I already have a *.webconverger.com certificate issued arn:aws:acm:us-east-1:407461997746:certificate/5efcc663-6e6c-43b3-bab0-49ad36b27152 so I am a little puzzled why it is:
- creating a webconverger.com one instead of a talks.webconverger.com one
- not simply using the existing wildcard certificate
Environment
Archlinux user
[hendry@t480s static-site]$ git describe --always
e8d9b04
[hendry@t480s static-site]$ cdk --version
1.3.0 (build bba9914)
Issue Analytics
- State:
- Created 4 years ago
- Comments:10 (3 by maintainers)
Top Results From Across the Web
Resolve the "InvalidViewerCertificate" error exception when ...
This error message indicates that the alternate domain names (CNAMEs) on the distribution aren't covered by the Subject Alternative Name (SAN) ...
Read more >Subdomain on CloudFront not working (certificate not accepted)
Add the certificate to the distribution, then save changes, then add the subdomain as alternate domain name, and then save changes again. Any ......
Read more >Troubleshooting distribution issues - Amazon CloudFront
The certificate that you've attached doesn't cover the alternate domain name that you're trying to add. For each alternate domain name that you...
Read more >CloudFront InvalidViewerCertificate Error Exception - Bobcares
“To add an alternate domain name (CNAME) to a CloudFront distribution, you must attach a trusted certificate that validates your ...
Read more >Error error creating CloudFront Distribution ... - Edureka
Error: error creating CloudFront Distribution: InvalidViewerCertificate: To add an alternate domain name (CNAME) to a CloudFront distribution, ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
I’m using Terraform now: https://github.com/kaihendry/dabase.com/blob/master/terraform/s3.tf
Not sure why I didn’t think of using Terraform before. It’s saner than JS/TS and being locked into a single Cloud provider.
I have managed to work round the problem. See here: https://github.com/davidsteed/awscdkstaticsite