1 Answer
- Newest
- Most votes
- Most comments
2
That error means the DNS name is already configured for another CloudFront distribution. It might be in a different AWS account. Each name configured for a CloudFront distribution must be globally unique to that distribution.
First make sure you've associated a TLS certificate with your distribution for the name (or a wildcard that covers it) you want to configure as its alias. Then use the CLI command aws cloudfront list-conflicting-aliases --distribution-id <id-of-your-distribution> --alias <dns-name-you-want> (https://awscli.amazonaws.com/v2/documentation/api/latest/reference/cloudfront/list-conflicting-aliases.html) to find partial IDs of the AWS account and the CloudFront distribution that is using the conflicting name.

Thank you! I updated the answer, conflicting DistributionId & AccountId are not mine!