I've always been a crontab guy. Recently I have decided to make the switch to Apple's launchd processes, and I am unable to get my first plist to run.
plutil -lintcommand tells me the plist is formatted correctly. Actually, it outputs "OK".
I have run the bash script manually and confirmed that it properly operates when manually initiated.
I have loaded the file using launchctl load and received the response "already loaded" on repeated attempts to do the same.
The problem must be in my PLIST definition. Please help me spot the error.
I expect this to run with the following conditions:
- Only while the user
jaredclemenceis using the system
- Once immediately on login
- Every 15 minutes thereafter
- Change Directory to
/Library/WebServer/Documents/medface/before running the script.
The plist file is as follows:
<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> <plist version="1.0"> <dict> <key>Label</key> <string>org.pediatricheartcenter.medface.crons</string> <key>User</key> <string>jaredclemence</string> <key>ProgramArguments</key> <array> <string>/User/jaredclemence/runMedfaceSchedTasks.batch</string> </array> <key>WorkingDirectory</key> <string>/Library/WebServer/Documents/medface</string> <key>StartInterval</key> <integer>900</integer> <key>RunAtLoad</key> <true/> </dict> </plist>
- I have stored the file in
- A previous version of the file used
<string>value instead of an array.