Adobe Update Server Nightly Sync

From AFP548 Wiki
Jump to navigation Jump to search

With CS5, Adobe has added the ability to have a local software update server. While the script works nice, it needs to be run manually to sync against Adobe's servers. Below are scripts I made to automatically sync the updates every night.

LaunchDaemon

edu.pct.AdobeUpdateSync.plist - Place in /Library/LaunchDaemons - Load with launchctl load /Library/LaunchDaemons/edu.pct.AdobeUpdateSync.plist - Permissions should be root:wheel with 644 permissions.

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
	<key>Label</key>
	<string>edu.pct.AdobeUpdateSync</string>
	<key>ProgramArguments</key>
	<array>
		<string>/usr/local/bin/asus-wrapper.sh</string>
	</array>
	<key>StartCalendarInterval</key>
	<dict>
		<key>Hour</key>
		<integer>5</integer>
		<key>Minute</key>
		<integer>0</integer>
	</dict>
</dict>
</plist>

Sync Script

Here is the script that actually does the syncing. Place this in /usr/local/bin as root:staff, 755 permissions.

#!/bin/sh
DATE=`date "+%m%d%y-%H%M%S"`
echo "--------------------------------" >> /var/log/asus-sync.log
echo "Date: ${DATE}" >> /var/log/asus-sync.log
echo "2" | /Applications/AdobeUpdateServerSetupToolCS5.app/Contents/MacOS/AdobeUpdateServerSetupToolCS5 --root="/Volumes/Storage1/Adobe Updates/CS5" >> /var/log/asus-sync.log
echo "--------------------------------" >> /var/log/asus-sync.log

This currently logs to /var/log/asus-sync.log, this way you can see whats going on.

Note for AUSST2.0

There shouldn't need to be anything special. I've dropped the 2.0 tool along side the 1.0, and just updated the asus-wrapper.sh file to read "AdobeUpdateServerSetupTool2.0" instead of "AdobeUpdateServerSetupToolCS5"