Mac - Run java program at launch
Posted
by
emd
on Super User
See other posts from Super User
or by emd
Published on 2013-10-28T02:52:47Z
Indexed on
2013/10/28
3:58 UTC
Read the original article
Hit count: 530
I want to launch a java program (server program) at computer start up. I can run it from the command line perfectly.
I created /Library/Server/startFS.sh. The file is executable by root and contains:
cd /Library/Server/FiloSync
/usr/bin/java -jar /Library/Server/FiloSync/filosync-server-latest.jar -p 7000 -s 7001
I can't get my launchd plist included here, the formatting is all off.
I can run it fine from the command line: './startFS.sh' but when I put create the plist (via Lingon), nothing happens.
Now, when run, it outputs a few lines to the console. Might that be problem??
I have tried prepending 'nohup' and post pending '&', but no combination seems to work.
Help please.
© Super User or respective owner