Questions tagged [amazon-cloudfront]

Amazon CloudFront is a web service for content delivery. It integrates with other Amazon Web Services to give developers and businesses an easy way to distribute content to end users with low latency, high data transfer speeds, and no commitments.

Docs

3904 questions
255
votes
10 answers

When to use Amazon Cloudfront or S3

Are there use cases that lend themselves better to Amazon cloudfront over s3 or the other way around? I'm trying to understand the difference between the 2 through examples.
Kamo
  • 3,027
  • 2
  • 17
  • 20
196
votes
6 answers

Serving gzipped CSS and JavaScript from Amazon CloudFront via S3

I've been looking for ways of making my site load faster and one way that I'd like to explore is making greater use of Cloudfront. Because Cloudfront was originally not designed as a custom-origin CDN and because it didn't support gzipping, I have…
Donald Jenkins
  • 3,425
  • 7
  • 30
  • 34
163
votes
13 answers

Font from origin has been blocked from loading by Cross-Origin Resource Sharing policy

I'm receiving the following error on a couple of Chrome browsers but not all. Not sure entirely what the issue is at this point. Font from origin 'https://ABCDEFG.cloudfront.net' has been blocked from loading by Cross-Origin Resource Sharing…
Dallas Clark
  • 3,894
  • 3
  • 26
  • 33
147
votes
13 answers

Force CloudFront distribution/file update

I'm using Amazon's CloudFront to serve static files of my web apps. Is there no way to tell a cloudfront distribution that it needs to refresh it's file or point out a single file that should be refreshed? Amazon recommend that you version your…
Martin
  • 4,897
  • 11
  • 40
  • 59
112
votes
12 answers

How do you set a default root object for subdirectories for a statically hosted website on Cloudfront?

How do you set a default root object for subdirectories on a statically hosted website on Cloudfront? Specifically, I'd like www.example.com/subdir/index.html to be served whenever the user asks for www.example.com/subdir. Note, this is for…
wyer33
  • 5,388
  • 3
  • 19
  • 42
101
votes
17 answers

Unable to select Custom SSL Certificate (stored in AWS IAM)

I am going to create a new distribution at CloudFront. Already I have uploaded my SSL certificate at AWS IAM using AWS CLI. That certificate appears in the Custom SSL Certificate dropdown on new distribution page but it is DISABLED. Can someone tell…
theGeekster
  • 5,421
  • 10
  • 31
  • 46
91
votes
5 answers

HTTPS for Amazon S3 static website

I want to host a HTTPS-only static website using Amazon S3 and CloudFront. Here's what I've done so far: Set up an S3 bucket for static website hosting and put my website files in it Created a CloudFront distribution and pointed it to the S3…
jamix
  • 5,115
  • 4
  • 23
  • 32
83
votes
6 answers

Correct S3 + Cloudfront CORS Configuration?

My application stores images on S3 and then proxies them through Cloudfront. I'm excited to use the new S3 CORS support so that I can use HTML5 canvas methods (which have a cross-origin policy) but can't seem to configure my S3 and Cloudfront…
kateray
  • 1,808
  • 3
  • 17
  • 23
82
votes
2 answers

Cloudfront redirect www to naked domain with ssl

Forgive me if this has been asked before, there are a number of resources that touch on this, but nothing seems to fit for my specific (https) use-case. I'm trying to redirect https://www.example.com to https://example.com. Likewise, this should…
Marc Greenstock
  • 10,636
  • 4
  • 27
  • 49
80
votes
4 answers

What is a TTL 0 in CloudFront useful for?

Some weeks ago Amazon announced that they have lowered the content expiration period: Amazon CloudFront Lowers Minimum Content Expiration Period So much that you can actually set now TTL in CloudFront to 0. So my question is, why could it be useful…
jatorre
  • 970
  • 1
  • 7
  • 6
75
votes
3 answers

Amazon CloudFront Doesn't Respect My S3 Website Bucket's index.html Rules

I'm hosting a static website on Amazon S3 using the static website hosting option, so that S3 will render a folder without making me explicitly point to my index.html file. For instance, here is a direct link to a page in my S3 bucket:…
rdegges
  • 27,994
  • 16
  • 73
  • 100
72
votes
5 answers

AWS CloudFront redirecting to S3 bucket

I have created a CloudFront distribution to serve the static website. S3 is origin server. Now if we access CloudFront URL, it redirects to S3 location. d2s18t7gwlicql.cloudfront.net or test.telekha.in In the browser it is…
Rajneesh
  • 1,815
  • 4
  • 17
  • 28
72
votes
3 answers

Amazon S3 Redirect and Cloudfront

I'm trying to setup 301 redirects on S3 using objects, referenced here http://docs.aws.amazon.com/AmazonS3/latest/dev/how-to-page-redirect.html. I've been having some problems and can't seem to figure out what I'm doing wrong. What I get is a…
Matt Smith
  • 3,309
  • 2
  • 25
  • 29
71
votes
14 answers

Cloudfront custom-origin distribution returns 502 "ERROR The request could not be satisfied." for some URLs

We have a Cloudfront distribution with custom origin that has been working just fine for quite a long time, serving static assets for one of our sites. Just this morning, we noticed that our logo was displaying as a broken link. Upon further…
David Eyk
  • 10,780
  • 10
  • 60
  • 97
68
votes
9 answers

CloudFront distribution not showing as Route53 alias target

I’m trying to add a route 53 record set that points to my cloudfront distribution. However, when I select ‘create record set’ in route 53 and click the alias target in the subsequent panel, the cloud front distribution is not listed. All I get is…
LDJ
  • 6,006
  • 8
  • 49
  • 78
1
2 3
99 100