8

I am setting up Amazon CloudFront to distribute the contents of an S3 bucket and it works fine when I use the xxxxxxx.cloudfront.net Amazon gives me.

However, I want to use static.mydomain.com to access my files. I have followed Amazon's instructions and have added a CNAME record from static.mydomain.com to xxxxxx.cloudfront.net and I have also specified that CNAME (static.mydomain.com) in my CloudFront distribution properties.

Still, I can't access my files from static.mydomain.com.

I am with MediaTemple and static.mydomain.com only serves me the default MediaTemple server page. When I request static.mydomain.com/myfile.css it gives me 'Sorry, invalid request'.

Any idea?

Jonathan Roy
  • 863
  • 11
  • 20

1 Answers1

8

you need to add your domain static.mydomain.com into "Alternate Domain Names(CNAMEs)" also make sure your files have read access to anyone, in other words, your files are public.

Paul Ma
  • 602
  • 6
  • 8