TweetFollow Us on Twitter

Unlocking Podcast Producer v2: Under the Hood

Volume Number: 26
Issue Number: 01
Column Tag: Podcasting

Unlocking Podcast Producer v2: Under the Hood

Customizing and extending workflows

by Michele (Mike) Hjörleifsson

Introduction

In the last article in this series, we took a the structure of a workflow in Podcast Composer, the new GUI tool in Snow Leopard creating workflows for Podcast Producer. Podcast Composer's export, publish and notification options will suite most administrators requirements, but its worth a review of what these are and what does an administrator do if they need to extend a workflow with other tools.

The default export options provide formats for iPod/iPhone, Apple TV, Computer, Audio Only, Mobile streaming and output to Compressor. The first five are accomplished using QuickTime X to transcode the video/audio into the appropriate format then hand them to the publishing stage. The Compressor option assumes that Compressor from Final Cut Studio is installed on the servers that will be doing the output and extends the number of types of transcoding an administrator can accomplish by leveraging the huge library of default Compressor output options as well as any plug-ins purchased from companies like TeleStream for output to Microsoft or Adobe Flash formats. Additionally utilizing Compressor allows administrators to leverage QMaster clustering technology to divide the transcoding operations to multiple computers running as QMaster agents. QMaster is included with Final Cut Studio (FCS) and does not require an additional license to be installed on any number of computers that form the cluster. With a single license of FCS and administrator can enable a large cluster of servers to handle these transcoding options.

Once the export stage is performed the output is handed to the publishing stage of the workflow where the podcast producer library receives the file by default (and is required for this stage), and the administrator has the additional options of sending notifications and/or export content to the Apple Wiki, File Transfer, Final Cut Server watch folder, a folder on the file system or even another workflow. Let's examine some of the options here.

The first option, Apple Wiki allows posting of content to the users default group wiki (default group is determined by Workgroup Manager or Active Directory), you must specify which user credentials are used to post the content. Which content type(s) to post (from the export types specified in the previous stage), or you can specify a custom blog or wiki to post to. For instance, if you have a blog called Daily Podcasts that has today's daily briefings you can post the podcasts directly to that blog versus the users blog or some other group wiki.

File transfer allows the administrator to pick the method that the exported item is being transmitted via: ftp, ftps, sftp, webdav or webdavs. This transfer can take place to another server on your network or across the world. As expected you would need to provide credentials appropriate to the service you select.

The next option allows you to export to a watch folder for Final Cut Server (FCS), where FCS will take the exported file and perform it's own workflow on that content, such as notifying editors, making a proxy copy of the content for laptop editing or any of a myriad of options supplied by FCS.

An administrator can also use the Folder publish option which simply drops the specified output(s) to a folder on a local or remote (must be previously mounted and accessible by all servers in the Podcast Producer cluster) file system for review or further processing. If you're experienced with Apple Script or Automator, you can attach additional actions to that folder that execute once content is placed there by Podcast Producer.

The last option allows you to create cascading workflows by submitting the output of one workflow to another workflow. Why would an administrator want to send content from one workflow to another? Well lets say you want all of your content archived onto a SAN in your data center, you can create a workflow that simply drops the files onto your SAN and then have all your other workflows call that as part of their workflow option. This would be more prevalent when administrators allow content publishers to create their own workflows but wants to standardize some of the output or notification options.

The next stage of the workflow, Notification allows the administrator to notify users and groups that the content is ready by email, iChat, iTunes Directory posting, iTunesU posting, or posting to a Web Service. Let's look at the options here:

Email Notification allows the workflow creator to specify whether to send the email notification to the Podcast Producer Administrator, the submitting user, both and or others. You will need to provide an email address and email server information so the service can facilitate delivery of the email. If you would like to change the format or design of the emails, you can. Please refer to the Podcast Administrator document located here:

http://images.apple.com/server/macosx/docs/Podcast_Producer_Admin_v10.6.pdf

iChat Notification allows the workflow creator to select the Podcast Producer Administrator, the submitting user, both and or others be notified by iChat. An iChat server id, password and the iChat message to send need to be specified.

iTunes Podcast Directory, this feature will post your podcast content to iTunes. For this notification to work, you must setup your feeds and be registered with iTunes. When this notification is sent to iTunes, the iTunes podcast repository syncs with your Podcast Library as soon as possible to reflect all changes.

The iTunesU feature is strictly for educational institutions that are setup with an iTunesU site(s). Simply specify the iTunes U site that you would like the workflow to update and that is all there is to it.

The Service setting allows the workflow creator to specify an external web service that is designed to accept publication notifications.

Podcast Composer provides a fairly comprehensive set of options for administrators to choose from, but what if your organization needs to take it a step further? For instance, what if your podcasts are actually testimonial depositions for a legal case and you need to digitally sign them to ensure their authenticity for potential court proceedings at a later time? What if you have to create some other format that isn't included as a QuickTime or Compressor option? Podcast workflows are simply an OS X bundle, similar to an application or other type of OS X bundle. So you can open the workflow's contents and examine and modify it, but before you go hacking away let's take a look at the bundle itself and the ramifications of editing one.

Create a new workflow with a few options in Podcast Composer and save it to your desktop. You must specify at least a few options for Podcast Composer to create the directories and files we are going to look at. Once created, Ctrl Click or right click and select Show Package contents to view the contents of the bundle. You will find a single folder labeled Contents. Open this folder and you will see 2 more items, Info.plist and a Resources folder. The Info.plist file contains an identifier for the bundle, its name, language, and other house keeping information including some unique identifier strings. While you could create a workflow totally from scratch the values in this file are somewhat of a pain to collect and may change with any OS X update, so it is preferable to create the majority of your workflow in Podcast Composer then edit a couple of files and locations. Opening the Resource folder exposes the items we are truly looking for.


As you can see in the screenshot there are several plist files and directories in the Resource folder. Primarily you will only modify a few items here. Namely, the template.plist and the Tools, Presets, Images, or Movies directories. The template.plist specifies the workflow tasks, dependencies and order of actions. This is where you would add any additional steps you require to perform during your podcast workflow, we will explore this in more detail in just a moment. The Images and Movies directories are where you would add any custom movie or image files your scripts or additional workflow tasks may need. You do not need to put leading or trailing videos in these directories, it's easier to specify those in Podcast Composer. Though you could easily change all your leading/trailing videos for all your workflows by writing a script to replace the old intro movie with a new intro movie in the Movie directory of all your workflows, of course you would need to ensure the permissions stay consistent. The Presets directory stores preset encoding to use for each of your selected export options, the defaults usually do the trick. The Compositions directory stores Quartz Composer compositions that are used in the workflow, typically the title introduction and movements of dual source videos. The Templates directory is used to hold any modified templates for your email, iChat or other notifications; by default this directory is empty and the standard system-wide templates will be used. Delving into the plist files in alphabetical order:

accounts.plist - doesn't seem to be used at this time but is designed to store credential information used by Podcast Composer.

configuration.plist - Stores the configurations of the Import, Edit, Export, Notify, and Publish stages of Podcast Composer.

sources.plist - Specifies the type of content processed by the workflow.

template.plist - Specifies the tasks to execute and the order of execution.

Extending your workflow to execute a predetermined script or other action is simply a matter of putting that script in the Tools directory and modifying the template.plist file to add the step for that script into the workflow. Opening the templates.plist file with Plist Editor (included as part of Xcode) reveals the contents and structure of the file as seen below.


Moving from top to bottom, there is the root of the plist file, then a dictionary named Item 0. Clicking the disclosure triangle to expose the contents of Item 0 exposes the heart of the plist file. The plist file is divided into four sections. artConditions, artSpecifications, taskSpecifications, and userRequirements. There are two additional items in the base of Item 0, name for the Xgrid job and notification email of an administrator.

The "art" prefixed files are used by Xgrid and should not be modified when creating a customized workflow. The userRequirements specify the required input from the user submitting the workflow and provide the default Title and Description though additional information could be required and added to this section.

The main section we are concerned with is the taskSpecifications, this is where the item-by-item execution of the workflow is read, prerequisites determined and then executed. The order of the items listed here serves as a graphical indicator of the order of execution though the prerequisites of each of the task items must be met prior to their execution or they will fail. Each task represents a UNIX shell script command and consists of the following elements:

arguments - Lists the arguments required by the command.

command - Specifies the command to run (including the path).

dependsOnTasks - (Optional) Lists the tasks that must be completed before this command runs.

So it's that easy: we just specify the command line of our script, arguments and any dependency on prior steps right? Wrong. There is one UNIX command called pcastaction that has been built to handle the majority of heavy lifting for the standard processing, export, and notifications options. So how do you specify a shell script, python, ruby or other command line executable that you want to use to customize your workflow? Enter pcastaction shell there is an argument you can pass to pcastaction called shell that specifies that you want to execute a shell command after which you can specify the arguments to send to that command like the filename to process etc. There are two-dozen or so replacement keys that can be specified to pass information to your script.Table 1 is a comprehensive list.


How would this work if we wanted to add a processing step to our workflow that executed a shell script called changeme.py to make some changes to our content? First place the changeme.py in the Tools directory and check to ensure its permissions follow the permissions of the balance of the directory. Second open the template.plist with Plist Editor, click the disclosure triangle on Root, click the disclosure triangle on Item 0 and click the disclosure triangle on taskSpecifications. Click on the word taskSpecification and a branching icon will appear to the right, click that to create a new branch (also called child) as seen here.


Change the entry's name from "New Item" to something more appropriate to your script, lets call that "generate-videoxml" for right now, change the type to "Dictionary" and drag it down to the bottom of the taskSpecification list (be careful not to drag it into the userRequirements branch.) Create 3 branches/children to your new generate-videoxml task item. Name the first one dependsOnTasks, the second one arguments and the third one command and set their types to Array, Array and String respectively. The processing is case sensitive so be aware of your case. So now we have a task with dependencies, arguments and command properties, lets edit these and enter some details for our workflow step.

Click the dependsonTasks and create a child/branch called Item 0 (the default name) of type string and put preflight in the value. This will tell Podcast Producer that this step requires the execution of the preflight step first. You can modify this to whatever step your workflow may require for your script to have the proper content as its input. Next, click on command and enter /usr/bin/pcastaction as the command's value. Now onto the heart of the matter, the arguments. Click on arguments and create 4 items of type string they will name themselves automatically as Item 0 à Item 3 which is fine for our purposes.

In Item 0, enter the value shell to tell Podcast producer that we will be executing a shell script, then in Item 1 enter the value $$Workflow Resource Path$$/Tools/changeme.py to tell Podcast producer where our script is actually located. Now you can add as many arguments you need to pass to your script as you deem necessary. The standard notation for the arguments is to preface them with a double hyphen (i.e. —description=$$Description$$ ). Your script will need to be able to parse these arguments and process them accordingly. Once you have completed your editing you can save your plist file. Now you have a workflow that executes a few steps set in Podcast Composer then your custom step. Unfortunately you can no longer open this workflow with Podcast Composer so you will have to manually verify and submit your new workflow.

Verifying the workflow is a fairly simple process, and will check the validity of your template.plist and the existence of the script specified but NOT that it will actually execute properly so some post install debugging may be needed and the Podcast Producer Application Error Log and /Library/Logs/pcastserverd/Diagnostic Reports/ are good areas to look at to trace your workflow's execution and success or failure. To verify your workflow zip up the workflow bundle. copy it to your server, unzip then execute

sudo pcastconfig -validate_workflow_at_path <Path to your workflow>

This will validate the xml formatting of template.plist and location any specified scripts. Once validated you can install the workflow by executing the pcast command:

sudo pcast -install_workflow -path <path to your workflow>

You will see some progress indications that your workflow has been copied up to the Podcast Producer service and installed. You may have to restart Podcast Producer from server admin or the command line:

sudo serveradmin stop pcastserverd
sudo serveradmin start pcastserverd

This will cause the workflow list to repopulate and your workflow will be available from the Podcast Capture application and web interface.

Conclusion

From the default configuration options available with Podcast Composer and the ability to add your own scripts to extend these workflows to anything your heart desires Podcast Producer provides a powerful media production streamlining and distribution tool for a myriad of uses from simple podcasting of lectures to complex multi-dimensional output. If your organization utilizes custom teleconferencing gear like Tandberg or other manufacturers you can, with a little work integrate these into your Podcast Producer workflow by examining the man pages for the various services and determining the appropriate method for submitting your content file to your custom workflow, the opportunities are endless. Well that is all for Podcast Producer for now, Till next time... Happy tech'ng.


Michele (Mike) Hjörleifsson has been programming Apple computers since the Apple II+, and implementing network and remote access security technologies since the early '90s. He has worked with the nation's largest corporations and government institutions. Mike is currently a certified Apple trainer and independent consultant. Feel free to contact him at mhjorleifsson@me.com

 

Community Search:
MacTech Search:

Software Updates via MacUpdate

Latest Forum Discussions

See All

Aether Gazer unveils Chapter 16 of its m...
After a bit of maintenance, Aether Gazer has released Chapter 16 of its main storyline, titled Night Parade of the Beasts. This big update brings a new character, a special outfit, some special limited-time events, and, of course, an engaging... | Read more »
Challenge those pesky wyverns to a dance...
After recently having you do battle against your foes by wildly flailing Hello Kitty and friends at them, GungHo Online has whipped out another surprising collaboration for Puzzle & Dragons. It is now time to beat your opponents by cha-cha... | Read more »
Pack a magnifying glass and practice you...
Somehow it has already been a year since Torchlight: Infinite launched, and XD Games is celebrating by blending in what sounds like a truly fantastic new update. Fans of Cthulhu rejoice, as Whispering Mist brings some horror elements, and tests... | Read more »
Summon your guild and prepare for war in...
Netmarble is making some pretty big moves with their latest update for Seven Knights Idle Adventure, with a bunch of interesting additions. Two new heroes enter the battle, there are events and bosses abound, and perhaps most interesting, a huge... | Read more »
Make the passage of time your plaything...
While some of us are still waiting for a chance to get our hands on Ash Prime - yes, don’t remind me I could currently buy him this month I’m barely hanging on - Digital Extremes has announced its next anticipated Prime Form for Warframe. Starting... | Read more »
If you can find it and fit through the d...
The holy trinity of amazing company names have come together, to release their equally amazing and adorable mobile game, Hamster Inn. Published by HyperBeard Games, and co-developed by Mum Not Proud and Little Sasquatch Studios, it's time to... | Read more »
Amikin Survival opens for pre-orders on...
Join me on the wonderful trip down the inspiration rabbit hole; much as Palworld seemingly “borrowed” many aspects from the hit Pokemon franchise, it is time for the heavily armed animal survival to also spawn some illegitimate children as Helio... | Read more »
PUBG Mobile teams up with global phenome...
Since launching in 2019, SpyxFamily has exploded to damn near catastrophic popularity, so it was only a matter of time before a mobile game snapped up a collaboration. Enter PUBG Mobile. Until May 12th, players will be able to collect a host of... | Read more »
Embark into the frozen tundra of certain...
Chucklefish, developers of hit action-adventure sandbox game Starbound and owner of one of the cutest logos in gaming, has released their roguelike deck-builder Wildfrost. Created alongside developers Gaziter and Deadpan Games, Wildfrost will... | Read more »
MoreFun Studios has announced Season 4,...
Tension has escalated in the ever-volatile world of Arena Breakout, as your old pal Randall Fisher and bosses Fred and Perrero continue to lob insults and explosives at each other, bringing us to a new phase of warfare. Season 4, Into The Fog of... | Read more »

Price Scanner via MacPrices.net

New today at Apple: Series 9 Watches availabl...
Apple is now offering Certified Refurbished Apple Watch Series 9 models on their online store for up to $80 off MSRP, starting at $339. Each Watch includes Apple’s standard one-year warranty, a new... Read more
The latest Apple iPhone deals from wireless c...
We’ve updated our iPhone Price Tracker with the latest carrier deals on Apple’s iPhone 15 family of smartphones as well as previous models including the iPhone 14, 13, 12, 11, and SE. Use our price... Read more
Boost Mobile will sell you an iPhone 11 for $...
Boost Mobile, an MVNO using AT&T and T-Mobile’s networks, is offering an iPhone 11 for $149.99 when purchased with their $40 Unlimited service plan (12GB of premium data). No trade-in is required... Read more
Free iPhone 15 plus Unlimited service for $60...
Boost Infinite, part of MVNO Boost Mobile using AT&T and T-Mobile’s networks, is offering a free 128GB iPhone 15 for $60 per month including their Unlimited service plan (30GB of premium data).... Read more
$300 off any new iPhone with service at Red P...
Red Pocket Mobile has new Apple iPhones on sale for $300 off MSRP when you switch and open up a new line of service. Red Pocket Mobile is a nationwide MVNO using all the major wireless carrier... Read more
Clearance 13-inch M1 MacBook Airs available a...
Apple has clearance 13″ M1 MacBook Airs, Certified Refurbished, available for $759 for 8-Core CPU/7-Core GPU/256GB models and $929 for 8-Core CPU/8-Core GPU/512GB models. Apple’s one-year warranty is... Read more
Updated Apple MacBook Price Trackers
Our Apple award-winning MacBook Price Trackers are continually updated with the latest information on prices, bundles, and availability for 16″ and 14″ MacBook Pros along with 13″ and 15″ MacBook... Read more
Every model of Apple’s 13-inch M3 MacBook Air...
Best Buy has Apple 13″ MacBook Airs with M3 CPUs in stock and on sale today for $100 off MSRP. Prices start at $999. Their prices are the lowest currently available for new 13″ M3 MacBook Airs among... Read more
Sunday Sale: Apple iPad Magic Keyboards for 1...
Walmart has Apple Magic Keyboards for 12.9″ iPad Pros, in Black, on sale for $150 off MSRP on their online store. Sale price for online orders only, in-store price may vary. Order online and choose... Read more
Apple Watch Ultra 2 now available at Apple fo...
Apple has, for the first time, begun offering Certified Refurbished Apple Watch Ultra 2 models in their online store for $679, or $120 off MSRP. Each Watch includes Apple’s standard one-year warranty... Read more

Jobs Board

DMR Technician - *Apple* /iOS Systems - Haml...
…relevant point-of-need technology self-help aids are available as appropriate. ** Apple Systems Administration** **:** Develops solutions for supporting, deploying, Read more
Omnichannel Associate - *Apple* Blossom Mal...
Omnichannel Associate - Apple Blossom Mall Location:Winchester, VA, United States (https://jobs.jcp.com/jobs/location/191170/winchester-va-united-states) - Apple Read more
Operations Associate - *Apple* Blossom Mall...
Operations Associate - Apple Blossom Mall Location:Winchester, VA, United States (https://jobs.jcp.com/jobs/location/191170/winchester-va-united-states) - Apple Read more
Cashier - *Apple* Blossom Mall - JCPenney (...
Cashier - Apple Blossom Mall Location:Winchester, VA, United States (https://jobs.jcp.com/jobs/location/191170/winchester-va-united-states) - Apple Blossom Mall Read more
IT Systems Engineer ( *Apple* Platforms) - S...
IT Systems Engineer ( Apple Platforms) at SpaceX Hawthorne, CA SpaceX was founded under the belief that a future where humanity is out exploring the stars is Read more
All contents are Copyright 1984-2011 by Xplain Corporation. All rights reserved. Theme designed by Icreon.