I'm trying to launch a faceless server application with it's associated project using shell script on OSX 10.10.4.
The shell script has been set to executable.
On Startup nothing happens to launch Wakanda\ Server.app/Contents/MacOS/Wakanda\ Server.
Please help me make this work.
The shell script is at:
Macintosh HD:Library:StartupItems:DispatchStartup:DispatchStartup.sh
The contents of this shell script is:
#!/bin/sh
. /etc/rc.common
# The start subroutine
StartService() {
# Insert your start command below. For example:
/Applications/Wakanda\ Server.app/Contents/MacOS/Wakanda\ Server --solution=/Applications/Dispatch/Dispatch\ Solution/Dispatch.waSolution
# End example.
}
# The stop subroutine
StopService() {
# Insert your stop command(s) below. For example:
killall -TERM /Applications/Wakanda\ Server.app/Contents/MacOS/Wakanda\ Server
sleep 15
killall -9 /Applications/Wakanda\ Server.app/Contents/MacOS/Wakanda\ Server
# End example.
}
# The restart subroutine
RestartService() {
# Insert your start command below. For example:
killall -HUP /Applications/Wakanda\ Server.app/Contents/MacOS/Wakanda\ Server
# End example.
}
RunService "$1"
//-------------------------------------------------------------------
// next to the shell script is StartParameters.plist //--------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist SYSTEM "file://localhost/System/Library/DTDs/PropertyList.dtd">
<plist version="0.9">
<dict>
<key>Description</key>
<string>Wakanda Server</string>
<key>OrderPreference</key>
<string>Late</string>
<key>Provides</key>
<array>
<string>Web service to database and objects</string>
</array>
<key>Uses</key>
<array>
<string>Network</string>
</array>
</dict>
</plist>