Search code examples
amazon-web-servicesamazon-s3amazon-cloudfrontamazon-route53

AWS route 53 subdomain/ s3 bucket with cloudFront


I have two websites (https://website1.com and https://website2.com) hosted on two different AWS account:

What I want to achieve: I want https://website2.com to be displayed on https://subdomain.website1.com.

So far I have defined a simple record in route 53 with the following:

  • name: subdomain.website1.com
  • type: CNAME
  • Route traffic to: IP address
  • Value: ???

What should I add in the value field? The IP of the cloudFront used to display https://website2.com?


Solution

  • Each CloudFront distribution has a name, you can grab it from CloudFront object. take the cname and use it for the route53 record