Search code examples
iosvideo-streamingamazon-cloudfront

Video distribution to iPhone with Amazon Cloudfront, with fixed content programming


I would like to set up a scalable video distribution server/infrastructure for streaming video to iOS devices. The client will have some programming of pre-produced content, e.g. 6 hours that will be played and then repeated from the beginning. It should be possible to enter the exact schedule when the video starts, and also the possibility to have it start at different times on different days.

I've been pointed to the Live Smooth Streaming offer from Amazon, using the Amazon CloudFront.

So my question to you: does this support the features I need, and how do I get it set up properly. I've already taken a look at their documentation at http://awsdocs.s3.amazonaws.com/CF/latest/cf_dg.pdf but that didn't cover the use case I want, namely setting up some programming scheme. I've seen references to Cloudformation templates for the live streaming but is there also s.th. similar for doing the fixed programming, or maybe it can be used for that too?

Thanks for your time!

Flo


Solution

  • Your question is a bit mixed up. iOS devices need HLS protocol content. You simply need to create your content in HLS form [ts files with .m3u8] and store in a S3 bucket and link your cloudfront to it.

    Since you mention pre-produced content i am guessing it means that it is available beforehand and not generated live.

    Your program then should point to the right .m3u8 file to pick and can update the .m3u8 file appropriately. Your program which controls access to the m3u8 (when its available what should be playable etc) is independent of the storage in s3/cloudfront.

    You can also generate content live but nothing changes except content is getting created on the fly. Your program controlling the .m3u8 will control what the client gets access to.

    If it was not for iOS devices but also other devices, the same would apply. Keep your content on S3 bucket and link to CF. You need your content in the format the device needs. Let your webserver program control access to the content. Remember CF is not a player. CF provides support for flash server as well and you can use that as well.