ANS-C01 Question 296
Single answerAn organization has hosted a website using an Amazon S3 bucket configured as a static website. The organization wants to use a custom domain (example.com) for the website and enable HTTPS. Which DNS record type should be used to route traffic to the S3 bucket?
- A
A record
- B
CNAME record
- C
TXT record
- D
Alias record
Show answer and explanation
Correct answer: D
Explanation
When using Amazon Route 53 to route traffic to an S3 bucket configured as a static website, Alias records are the recommended choice. Alias records are designed for AWS resources and provide additional benefits over traditional DNS record types, such as supporting the root domain (e.g., example.com) without needing additional configuration. This makes Alias records the best option for the given scenario.
- A. Incorrect.
An A record maps a domain name to an IPv4 address. However, S3 buckets do not have a static IP address, so this option is not suitable.
- B. Incorrect.
A CNAME record maps a domain name to another domain name. However, Amazon Route 53 supports Alias records, which are specifically designed for AWS resources and provide better functionality, such as support for the root domain.
- C. Incorrect.
A TXT record is used to store arbitrary text or configuration information, such as domain verification or SPF records. It is unrelated to routing traffic to an S3 bucket.
- D. Correct.
An Alias record is designed to route traffic to AWS resources, such as S3 buckets, CloudFront distributions, and more. It supports root domains and does not require additional configuration for AWS-managed services.