You can create an encrypted mp3 using Zencoder's encryption settings:
{
"input": "s3://my-bucket/super-secret.mp3",
"output": [
{
"format":"mp3",
"url":"s3://my-bucket/super-secret-encrypted.mp3",
You can create an encrypted mp3 using Zencoder's encryption settings:
{
"input": "s3://my-bucket/super-secret.mp3",
"output": [
{
"format":"mp3",
"url":"s3://my-bucket/super-secret-encrypted.mp3",
| { | |
| "live_stream": true, | |
| "outputs": [ | |
| { | |
| "label": "rtmp300", | |
| "size": "480x270", | |
| "video_bitrate": 300, | |
| "live_stream": true | |
| }, | |
| { |
| <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <meta charset="utf-8"> | |
| <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"> | |
| <title></title> | |
| <meta name="description" content=""> | |
| <meta name="viewport" content="width=device-width"> | |
| <link href="http://vjs.zencdn.net/4.0/video-js.css" rel="stylesheet"> |
Assuming you already have the appropriate Akamai credentials, you should have some information like this:
Primary: rtmp://p.ep12345.i.akamaientrypoint.net/EntryPoint
Backup: rtmp://b.ep12345.i.akamaientrypoint.net/EntryPoint
User: ######
Pass: ******
Stream: [EVENT_ANGLE_BITRATE]@12345
Playback: http://zencoder_hd1_1-lh.akamaihd.net/[EVENT_ANGLE_BITRATE]@12345
| require 'rubygems' | |
| require 'zencoder' | |
| # Change these settings | |
| s3_bucket = '' | |
| Zencoder.api_key = '' | |
| # Quick test to make sure the variables above are set... | |
| if s3_bucket == '' || Zencoder.api_key == '' | |
| puts "It appears you haven't set your S3 bucket or Zencoder API key..." |
| !!! | |
| %html{ :xmlns => 'http://www.w3.org/1999/xhtml', :lang => 'en', 'xml:lang' => 'en' } | |
| %head | |
| %title Zenquest | |
| %meta{ 'http-equiv' => 'Content-Type', :content => 'text/html; charset=utf-8' } | |
| %link{ :rel => 'stylesheet', :href => '//netdna.bootstrapcdn.com/twitter-bootstrap/2.2.1/css/bootstrap.no-responsive.no-icons.min.css', :type => 'text/css' } | |
| %link{ :rel => 'stylesheet', :href => '//netdna.bootstrapcdn.com/font-awesome/2.0/css/font-awesome.css', :type => 'text/css' } | |
| %link{ :rel => 'stylesheet', :href => '/screen.css', :type => 'text/css' } | |
| %body |
| // Mixins | |
| @mixin hover-ease($element, $time) { | |
| -moz-transition: $element $time + s ease; | |
| -o-transition: $element $time + s ease; | |
| -webkit-transition: $element $time + s ease; | |
| -ms-transition: $element $time + s ease; | |
| } | |
| @mixin corners($radius) { | |
| -webkit-border-radius: $radius; | |
| -moz-border-radius: $radius; |
| # Controller | |
| respond_to :html, :js | |
| # DELETE /users/1 | |
| def destroy | |
| @student = User.find(params[:id]) | |
| @student.destroy | |
| respond_with(@student) | |
| rescue | |
| puts $!.inspect, $@ | |
| render :nothing => true |