0

I am working on AWS HLS Media streaming using cloudfront. With the help of elastic transcoder content is transcoded as per the requirement.I have setup the cloudfront to access content present in s3 bucket.Whenever I try to access the video from HLS player like JWPlayer /online I get below error.

Cannot load m3u8 crossdomain access is denied.

On JW player I am getting below error.

This video file cannot be played. (Error Code: 232011)

My S3 bucket cors configuration file is

<CORSConfiguration xmlns="http://s3.amazonaws.com/doc/2006-03-01/">
<CORSRule>
    <AllowedOrigin>*</AllowedOrigin>
    <AllowedMethod>GET</AllowedMethod>
</CORSRule>
</CORSConfiguration>

Struggling to resolve this issue since last few days.Please help

Rohit
  • 895
  • 1
  • 9
  • 19
  • You also need to allow `HEAD`. This looks like a [duplicate of this question](https://stackoverflow.com/questions/53800705/cors-configuration-for-s3-hosted-hls-video-in-jw-player). – aergistal Apr 05 '19 at 07:03
  • HEAD is allowed with GET in CloudFront, you can try to enable GET, HEAD and OPTIONS request on CloudFront, Whitelist Origin header and invalidate the cache once after doing it and test it again. – James Dean Apr 05 '19 at 10:02

0 Answers0