You can use a wildcard eg. *.domain.com as the alternate domain name, but you must make sure that the SSL certificate configured in your CloudFront distribution is also valid for *.domain.com - see documentation here: https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/CNAMEs.html#alternate-domain-names-wildcard
Could you show your HostedZone configuration?
You can check 3 places
- Route 53 HostedZone
- CloudTrail Alias
- Certificate Manager
and verify if there is everything ok and proper domains/subdomains are configured.
- Please check if you have added your "www" domain in the list of Alternate domains in CloudFront configuration as Paul mentioned.
- And make sure the ACM SSL certificate you have configured in CloudFront should be valid for both www and root domain. If not create a new one with both domains and reconfigure the CloudFront.
- Why isn't my domain record in Route 53 that points to an Amazon S3 bucket or static website resolving?AWS OFFICIALUpdated 3 years ago
- AWS OFFICIALUpdated 6 months ago
- AWS OFFICIALUpdated a year ago
- EXPERTpublished 7 months ago