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

The secrets of Penacony might soon come...
Version 2.2 of Honkai: Star Rail is on the horizon and brings the culmination of the Penacony adventure after quite the escalation in the latest story quests. To help you through this new expansion is the introduction of two powerful new... | Read more »
The Legend of Heroes: Trails of Cold Ste...
I adore game series that have connecting lore and stories, which of course means the Legend of Heroes is very dear to me, Trails lore has been building for two decades. Excitedly, the next stage is upon us as Userjoy has announced the upcoming... | Read more »
Go from lowly lizard to wicked Wyvern in...
Do you like questing, and do you like dragons? If not then boy is this not the announcement for you, as Loongcheer Game has unveiled Quest Dragon: Idle Mobile Game. Yes, it is amazing Square Enix hasn’t sued them for copyright infringement, but... | Read more »
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 »

Price Scanner via MacPrices.net

Apple AirPods Pro with USB-C return to all-ti...
Amazon has Apple’s AirPods Pro with USB-C in stock and on sale for $179.99 including free shipping. Their price is $70 (28%) off MSRP, and it’s currently the lowest price available for new AirPods... Read more
Apple Magic Keyboards for iPads are on sale f...
Amazon has Apple Magic Keyboards for iPads on sale today for up to $70 off MSRP, shipping included: – Magic Keyboard for 10th-generation Apple iPad: $199, save $50 – Magic Keyboard for 11″ iPad Pro/... Read more
Apple’s 13-inch M2 MacBook Airs return to rec...
Apple retailers have 13″ MacBook Airs with M2 CPUs in stock and on sale this weekend starting at only $849 in Space Gray, Silver, Starlight, and Midnight colors. These are the lowest prices currently... Read more
Best Buy is clearing out iPad Airs for up to...
In advance of next week’s probably release of new and updated iPad Airs, Best Buy has 10.9″ M1 WiFi iPad Airs on record-low sale prices for up to $200 off Apple’s MSRP, starting at $399. Sale prices... Read more
Every version of Apple Pencil is on sale toda...
Best Buy has all Apple Pencils on sale today for $79, ranging up to 39% off MSRP for some models. Sale prices for online orders only, in-store prices may vary. Order online and choose free shipping... Read more
Sunday Sale: Apple Studio Display with Standa...
Amazon has the standard-glass Apple Studio Display on sale for $300 off MSRP for a limited time. Shipping is free: – Studio Display (Standard glass): $1299.97 $300 off MSRP For the latest prices and... Read more
Apple is offering significant discounts on 16...
Apple has a full line of 16″ M3 Pro and M3 Max MacBook Pros available, Certified Refurbished, starting at $2119 and ranging up to $600 off MSRP. Each model features a new outer case, shipping is free... Read more
Apple HomePods on sale for $30-$50 off MSRP t...
Best Buy is offering a $30-$50 discount on Apple HomePods this weekend on their online store. The HomePod mini is on sale for $69.99, $30 off MSRP, while Best Buy has the full-size HomePod on sale... Read more
Limited-time sale: 13-inch M3 MacBook Airs fo...
Amazon has the base 13″ M3 MacBook Air (8GB/256GB) in stock and on sale for a limited time for $989 shipped. That’s $110 off MSRP, and it’s the lowest price we’ve seen so far for an M3-powered... Read more
13-inch M2 MacBook Airs in stock today at App...
Apple has 13″ M2 MacBook Airs available for only $849 today in their Certified Refurbished store. These are the cheapest M2-powered MacBooks for sale at Apple. Apple’s one-year warranty is included,... Read more

Jobs Board

Licensed Practical Nurse - Womens Imaging *A...
Licensed Practical Nurse - Womens Imaging Apple Hill - PRN Location: York Hospital, York, PA Schedule: PRN/Per Diem Sign-On Bonus Eligible Remote/Hybrid Regular Read more
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
Operating Room Assistant - *Apple* Hill Sur...
Operating Room Assistant - Apple Hill Surgical Center - Day Location: WellSpan Health, York, PA Schedule: Full Time Sign-On Bonus Eligible Remote/Hybrid Regular Read more
Solutions Engineer - *Apple* - SHI (United...
**Job Summary** An Apple Solution Engineer's primary role is tosupport SHI customers in their efforts to select, deploy, and manage Apple operating systems and Read more
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
All contents are Copyright 1984-2011 by Xplain Corporation. All rights reserved. Theme designed by Icreon.