Relative Content

Tag Archive for amazon-web-servicesamazon-s3amazon-cloudfront

AWS Cloudfront returning a specific origin in access-control-allow-origin when it’s supposed to return *

I have a cloudfront distribution with an S3 bucket as the origin, in my cloudfront behaviour I have Response headers policy as SimpleCORS and Origin request policy as CORS-S3Origin, my S3 CORS configuration allows the domain I’m requesting from (both with www. and without), but Access-Control-Allow-Origin only returns the www. version for some reason, not letting me use the resource when I access the website without www.

Lag when streaming music from AWS S3 and Cloudfront

I’m building a music streaming app and I have all the musics stored in a S3 bucket.
I also set up a CDN with Cloudfront.
The problem is that when I go on my deployed site and I play any music it lags (it takes multiple seconds to play one second) but when I play it from the dev environment it works perfectly (I’m using the same database and bucket between my dev environment and my deployed site).
I don’t understand why there is a difference and what could be its origin.

Cloudfront access to bucket without S3 bucket policy?

I am attempting to set up a Cloudfront distribution to an S3 bucket as I’m specifically attempting to set up a referer policy. The problem is that Cloudfront seems to be ignoring the bucket policy completely. I don’t even have the Cloudfront policy set on this private S3 bucket, and yet I can still access all content through the Cloudfront distribution.