Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Subdomain point to Amazon S3 Bucket

I am a little bit confused with subdomain point to S3 bucket.

I have domain called mydomain.com from NameCheap.com and my hosting server is Hostgater.

So my website is up and running.

I have a lot of mp3 files. So I have created Amazon S3 bucket call media.mydomain.com

So I got my static s3 website URL as follow. http://media.mydomain.com.s3-website-ap-southeast-1.amazonaws.com/

I want to point this url to my subdomain, media.mydomain.com.

May I know how and where to point? NameCheap or Hostgator.

I have created subdomain in hostgator but it can only redirect to S3 URL

Thanks, Alex

like image 661
Alex Aung Avatar asked Aug 13 '16 07:08

Alex Aung


1 Answers

You can make a new DNS record in Namecheap for this task

In your Namecheap account, go to Manage your domain, then Advanced DNS, and Add new Record with CName type

  • Host: Enter your subdomain media
  • Value: Enter media.mydomain.com.s3-website-ap-southeast-1.amazonaws.com. (with a dot . at the end)
  • TTL: Automatic

Save all changes and wait for about 1 hour for the new record to take effect.

like image 66
Rocherlee Avatar answered Sep 25 '22 07:09

Rocherlee