DreamObjects and Video files

It looks like I will be delving into the realm of DreamObjects, as I have a project coming up that sounds like a good use-case for this. I am curious if experienced devs might agree, and any other thoughts before I start?

A client of mine would like a WordPress site where he can have videos that can be purchased for streaming OR downloading.
The videos are ones he makes…something to do with meditiation and yoga…so no pirated content or anything like that.

My first thought would be to use Youtube or Vimeo for the streaming, but then I thought this might a good chance to try out WordPress’s built in player. This would also make uploading each video a one-time thing since he wants his website visitors to be able to stream or download.

By using DreamObjects, I hope to avoid any run-ins with Dreamhost about taking up too much space or bandwidth.
Also, I have a vague impression that using DreamObjects would be slightly speedier for downloads…not sure where I got that idea from…read something somewhere.

At any rate, I will be doing some home-work on this today, but would like to hear from anyone who has inside knowledge on the proper use of DreamObjects, how it works with WordPress, good experiences, bad experiences, etc…

This is a pretty good use case for DreamObjects. Basically, you’ll want to upload the videos to a bucket, and ensure that each object (video) in the bucket is set to a “private” ACL, so that it cannot be read publicly.

Then, you can use the PHP libraries for accessing DreamObjects to generate temporary URLs to access videos on a one-by-one basis. Some documentation and examples for accessing DreamObjects with PHP are available here: http://docs.dreamobjects.net/s3-examples/php.html

The documentation includes an example for generating these temporary, signed URLs. Here is what it looks like:


<?php my $secret_url = $Connection->get_object_url('my-bucket-name', 'secret_plans.txt', '1 hour'); [/php] This would generate a URL for temporary access to a specific object, named 'secret_plans.txt', inside a bucket named 'my-bucket-name', with access for one hour. As for using with WordPress, I am not too familiar with the WordPress video tools, but I am guessing you'd be able to use one of these signed URLs as a "source" for streaming the video, as long as its in the right format. If you have videos are meant to be viewed publicly, I'd encourage you to enable DreamSpeed CDN on those videos, to accelerate the delivery of the content. For the private videos, you're better off streaming directly from DreamObjects.