Example of Compressor Commands
Following are examples of code for submitting common Compressor commands.
Cluster Names and IDs on a Local Network
The following command lists all of the cluster names and IDs on the local network.
/Applications/Compressor.app/Contents/MacOS/Compressor -show -timeout 10
This command has the following elements:
• Identifies where Compressor is located (the quotation marks are used because of the
space in “Final Cut Pro”).
• Shows all cluster names and IDs found.
• Sets the command to time out after ten seconds.
Submit a Job with No Password
The following submits a job to a cluster identified by a name that does not have a
password.
/Applications/Compressor.app/Contents/MacOS/Compressor -clustername MyCluster
-batchname "My First Batch" -jobpath ~/Movies/MySource.mov -settingpath
~/Library/Application\ Support/Compressor/Settings/MPEG-4.setting
-destinationpath ~/Movies/MyOutput.mp4 -timeout 5
This command has the following elements:
• Identifies where Compressor is located.
• Sends this job to the cluster named MyCluster.
• Assigns the batch name My First Batch (the quotation marks are used because of the
spaces).
• Finds the MySource.mov file for the job at ~/Movies/MySource.mov.
• Uses the MPEG-4 setting at ~/Library/Application\
Support/Compressor/Settings/MPEG-4.setting (the “\” character is used in this case to
retain the space in “Application Support”).
• Writes the output file, named MyOutput.mp4, to the ~/Movies folder.
• Sets the command to time out after five seconds of looking for the cluster.
397
Appendix C
Using the Command Line
Submit a Job with a Password
The following submits a job to a cluster identified by a name that does have a password.
/Applications/Compressor.app/Contents/MacOS/Compressor -clustername MyCluster
-password testpassword -batchname "My First Batch" -jobpath
~/Movies/MySource.mov -settingpath ~/Library/Application\
Support/Compressor/Settings/MPEG-4.setting -destinationpath
~/Movies/MyOutput.mp4 -timeout 5
This command has the following elements:
• Identifies where Compressor is located.
• Sends this job to the cluster named MyCluster.
• Submits the password “testpassword.”
• Assigns the batch name My First Batch.
• Finds the MySource.mov file for the job at ~/Movies/MySource.mov.
• Uses the MPEG-4 setting at ~/Library/Application\
Support/Compressor/Settings/MPEG-4.setting.
• Writes the output file, named MyOutput.mp4, to the ~/Movies folder.
• Sets the command to time out after five seconds of looking for the cluster.
Submit a Job Using a Cluster ID and No Password
The following submits a job to a cluster identified by an IP address that does not have a
password.
/Applications/Compressor.app/Contents/MacOS/Compressor -clusterid
"tcp://192.168.1.148:62995" -batchname "My First Batch" -jobpath
~/Movies/MySource.mov -settingpath ~/Library/Application\
Support/Compressor/Settings/MPEG-4.setting -destinationpath
~/Movies/MyOutput.mp4 -timeout 5
This command has the following elements:
• Identifies where Compressor is located.
• Sends this job to the cluster with the IP address of tcp://192.168.1.148 at port 62995.
• Assigns the batch name My First Batch.
• Finds the MySource.mov file for the job at ~/Movies/MySource.mov.
• Uses the MPEG-4 setting at ~/Library/Application\
Support/Compressor/Settings/MPEG-4.setting.
• Writes the output file, named MyOutput.mp4, to the ~/Movies folder.
• Sets the command to time out after five seconds of looking for the cluster.
398
Appendix C
Using the Command Line
Submit a Job Using a Cluster ID and an Inline Password
The following submits a job to a cluster identified by an IP address, with a user name and
an inline password.
/Applications/Compressor.app/Contents/MacOS/Compressor -clusterid
"tcp://username:testpassword@192.168.1.148:62995" -batchname "My First Batch"
-jobpath ~/Movies/MySource.mov -settingpath ~/Library/Application\
Support/Compressor/Settings/MPEG-4.setting -destinationpath
~/Movies/MyOutput.mp4 -timeout 5
This command has the following elements:
• Identifies where Compressor is located.
• Sends this job as “username” with the pasword “testpassword” to the cluster with the
IP address of tcp://192.168.1.148 at port 62995.
• Assigns the batch name My First Batch.
• Finds the MySource.mov file for the job at ~/Movies/MySource.mov.
• Uses the MPEG-4 setting at ~/Library/Application\
Support/Compressor/Settings/MPEG-4.setting.
• Writes the output file, named MyOutput.mp4, to the ~/Movies folder.
• Sets the command to time out after five seconds of looking for the cluster.
Submit a Job Using a Cluster ID and a Password
The following submits a job to a cluster identified by an IP address using a password, but
does not specify a user name.
/Applications/Compressor.app/Contents/MacOS/Compressor -clusterid
"tcp://192.168.1.148:62995" -password testpassword -batchname "My First
Batch" -jobpath ~/Movies/MySource.mov -settingpath ~/Library/Application\
Support/Compressor/Settings/MPEG-4.setting -destinationpath
~/Movies/MyOutput.mp4 -timeout 5
This command has the following elements:
• Identifies where Compressor is located.
• Sends this job to the cluster with the IP address of tcp://192.168.1.148 at port 62995
with the pasword “testpassword.”
• Assigns the batch name My First Batch.
• Finds the MySource.mov file for the job at ~/Movies/MySource.mov.
• Uses the MPEG-4 setting at ~/Library/Application\
Support/Compressor/Settings/MPEG-4.setting.
• Writes the output file, named MyOutput.mp4, to the ~/Movies folder.
• Sets the command to time out after five seconds of looking for the cluster.
399
Appendix C
Using the Command Line