Auto launcing an application for all users

Eyoung
Contributor

I ran across a neat little app via AFP548 for monitoring disk quotas for OD users.

the app works like a charm, but I am having issues with getting it to launch at login. I packaged up the app with a custom LaunchAgent plist... unfortunately my xml authoring is weak at best, so the app never launches. Anyone know of either an alternative casper way to make an app auto launch or see the glaring error in my plist below?

thanks.

{ Label = "org.thayer.QuotaMonitorMenu"; LaunchOnlyOnce = YES; ProgramArguments = ( open, "/Applications/QuotaMonitorMenu.app", ); RunAtLoad = YES; ServiceDescription = QuotaMonitorMenu;
}

------------------------------------------------
Man is the only animal that can remain on friendly terms with the victims he intends to eat until he eats them. - Samuel Butler

Eric Young
eyoung at thayer.org

3 REPLIES 3

Not applicable

I don't think launchd is designed to work with the "open" command. Try this instead:

ProgramArguments = ( "/Applications/QuotaMonitorMenu.app/Contents/MacOS/QuotaMonitorMenu",
);

Better yet, make it a login item that applies to all users. I posted a script awhile back that'll let you do that. Let me know if you want me to post it again.

Not applicable

I don't think launchd is designed to work with the "open" command. Try this instead:

ProgramArguments = ( "/Applications/QuotaMonitorMenu.app/Contents/MacOS/QuotaMonitorMenu",
);

Better yet, make it a login item that applies to all users. I posted a script awhile back that'll let you do that. Let me know if you want me to post it again.

tlarkin
Honored Contributor

Try the open command and deploy as a user agent in the user's ~/Library/LaunchAgents

<?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>com.startupapp.mycompany</string> <key>ProgramArguments</key> <array> <string>open -a QuotaMonitorMenu</string> </array> <key>RunAtLoad</key> <true/> </dict> </plist>