having programs launch on reboot

Puneet Kishor punk.kish at gmail.com
Mon Dec 19 12:03:21 PST 2011


On Dec 19, 2011, at 1:54 PM, Jeremy Lavergne wrote:

>> Nothing there about running them on reboot. However, another plist (vmware.plist) has the following switch
>> 
>> 	<key>RunAtLoad</key><true/>
> 
> From `man launchd.plist`:
>     RunAtLoad <boolean>
>     This optional key is used to control whether your job is launched once at
>     the time the job is loaded. The default is false.
> 
> Typically, as long as a launchd.plist doesn't have disabled set to true it will be run. You'd have to use one of the more advanced settings (watchpath, calendarinterval, etc) to get different behavior than simply on/off.
> 


so, in other words, I shouldn't worry about RunAtLoad, but change the Disabled key as follows

	<key>Disabled</key><false/>


Does that seem reasonable? Interestingly, on reading http://guide.macports.org/chunked/reference.startupitems.html, I tried the following

	$sudo launchctl load -w org.macports.apache2.plist 
	org.macports.apache2: Already loaded

I thought the -w switch was supposed to disable the "Disabled" key, but, as I said, the programs didn't start up automatically on reboot. I will try again.

--
Puneet Kishor


More information about the macports-users mailing list