bluemix u steam

25
© 2014 IBM Corporation creating embedded video in web with Bluemix Ustream Service Joseph Chang Senior IT Specialist IBM Software Group Document number https://ibm.biz/BdEzTZ

Upload: joseph-chang

Post on 08-Jul-2015

316 views

Category:

Internet


0 download

DESCRIPTION

Bluemix 於Nov 2014 增加了Ustram 服務,現在你可以輕易的在網頁中加放影像的功能。It's very easy. 本範例使用Node.js, 透過DevOps 服務修改佈署程式。 想要看範例: http://myustream.mybluemix.net/ 想要了解更多Bluemix請上: https://ibm.biz/BdEzTZ

TRANSCRIPT

Page 1: Bluemix u steam

© 2014 IBM Corporation

creating embedded video in web with Bluemix Ustream Service

Joseph Chang

Senior IT Specialist

IBM Software Group

Document number

https://ibm.biz/BdEzTZ

Page 2: Bluemix u steam

© 2014 IBM Corporation

Go to Bluemix with this url:

Source: If applicable, describe source origin

https://ibm.biz/BdEzTZ

Page 3: Bluemix u steam

© 2014 IBM Corporation

Registration

3

Login to bluemix after finishing sign up.

If you haven’t get an id, click Sign up to create one.

https://ibm.biz/BdEzTZ

Page 4: Bluemix u steam

© 2014 IBM Corporation

Create an Node.js server

4

Move to catalog. Click SDK for Node.js to create a web server.

https://ibm.biz/BdEzTZ

Page 5: Bluemix u steam

© 2014 IBM Corporation

Give your web a name

5

https://ibm.biz/BdEzTZ

Page 6: Bluemix u steam

© 2014 IBM Corporation

View the default web site.

6

Now the web server is running. Click the routes url to lauch the default sample page.

https://ibm.biz/BdEzTZ

Page 7: Bluemix u steam

© 2014 IBM Corporation

View the sample web page

7

The sample page looks like this.

Back to bluemix dashboard.

https://ibm.biz/BdEzTZ

Page 8: Bluemix u steam

© 2014 IBM Corporation

Add UStream service

8

Click “Add A Service”.

Scroll down to find Ustream.Click it.

https://ibm.biz/BdEzTZ

Page 9: Bluemix u steam

© 2014 IBM Corporation

Create Ustream Sevice

9

Click CREATE

https://ibm.biz/BdEzTZ

Page 10: Bluemix u steam

© 2014 IBM Corporation

Load video to Ustream

10

Click Ustream service to lauch the management console of Ustream.

Click it to go ahead.

https://ibm.biz/BdEzTZ

Page 11: Bluemix u steam

© 2014 IBM Corporation

Manage Videos

11

Here is ustream for bluemix management console. Click Manage videos.

https://ibm.biz/BdEzTZ

Page 12: Bluemix u steam

© 2014 IBM Corporation

Manage Videos

12

You can view the description of your videos.Click Upload to add a new one.

https://ibm.biz/BdEzTZ

Page 13: Bluemix u steam

© 2014 IBM Corporation

Upload Videos

13

To load video is simple. Just select it from your windows file explore and drop it here !!

https://ibm.biz/BdEzTZ

Page 14: Bluemix u steam

© 2014 IBM Corporation

Upload Videos

14

Drop videos. Fill in description. Click Start Upload.

The progression is shown here.

https://ibm.biz/BdEzTZ

Page 15: Bluemix u steam

© 2014 IBM Corporation

Get the Embed HTML Script

15

The video is loaded. We want to embed this video in the we page. Click the Embed button.

https://ibm.biz/BdEzTZ

Page 16: Bluemix u steam

© 2014 IBM Corporation

Get the Embed HTML Script

16

Click Copy to clipboard button. Save it somewhere.

<iframe src="//www.ustream.tv/embed/recorded/54778005?wmode=direct" style="border: 0 none transparent;" frameborder="no" width="480" height="302"></iframe><br /><a href="http://www.ustream.tv/" style="padding: 2px 0px 4px; width: 400px; background: #ffffff; display: block; color: #000000; font-weight: normal; font-size: 10px; text-decoration: underline; text-align: center;" target="_blank">Live streaming video by Ustream</a>

Back to Bluemix dashboard to modify web page in Node.js

https://ibm.biz/BdEzTZ

Page 17: Bluemix u steam

© 2014 IBM Corporation

Edit the web page

17

Click the ADD GIT button. Follow the instruction to create the source code repository and launch the editor.

https://ibm.biz/BdEzTZ

Page 18: Bluemix u steam

© 2014 IBM Corporation

Edit the web page

18

Open the views/body.jade. The source code is show like this:

https://ibm.biz/BdEzTZ

Page 19: Bluemix u steam

© 2014 IBM Corporation

Insert the tag for embedded video

19

Copy and paste the code to here.<iframe src="//www.ustream.tv/embed/recorded/54778005?wmode=direct" style="border: 0 none transparent;" frameborder="no" width="480" height="302"></iframe><br /><a href="http://www.ustream.tv/" style="padding: 2px 0px 4px; width: 400px; background: #ffffff; display: block; color: #000000; font-weight: normal; font-size: 10px; text-decoration: underline; text-align: center;" target="_blank">Live streaming video by Ustream</a>

https://ibm.biz/BdEzTZ

Page 20: Bluemix u steam

© 2014 IBM Corporation

Check-in the code

20

Click Git Repository botton.

https://ibm.biz/BdEzTZ

Page 21: Bluemix u steam

© 2014 IBM Corporation

Check-in the code

21

1 Click Select All .

2 Enter comment. 3 Commit

https://ibm.biz/BdEzTZ

Page 22: Bluemix u steam

© 2014 IBM Corporation

Deploy the code

22

4 Click Push All

https://ibm.biz/BdEzTZ

5 Click Build &Deploy

Page 23: Bluemix u steam

© 2014 IBM Corporation

Deploy the code

23

Check the status of the build & deploy.

6 Click the link to view the web page

https://ibm.biz/BdEzTZ

Page 24: Bluemix u steam

© 2014 IBM Corporation

Deploy the code

24

The video is embedded in the web page now !!View the video at: https://myustream.mybluemix.net

https://ibm.biz/BdEzTZ

Page 25: Bluemix u steam

© 2014 IBM Corporation25