Run OpenRemote 2.5 as daemon on OS X

I’ve installed OR Controller 2.5 on my Mac Mini running OS X 10.7.5 Lion.

Running the installation and getting it to sync with Designer was all pretty straight forward.

But now I would like to run OR as a daemon and get it to start and run without the need to login with a user account. I’ve constructed a plist-file (/Library/LaunchDaemons/com.openremote.plist) which at first didn’t seem to launch. After some further investigation though, it did appear to launch my start.sh script which eventually runs “openremote.sh start”.

I’ve traced the execution of openremote.sh until it’s executeTomcat() function. When starting by hand (sudo ./openremote.sh start) the controller runs fine under the root account. When launched through launchd nothing happens.

In both cases, with all variables resolved, the execution is as follows:

eval ("/System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home/bin/java"
-Dcatalina.home="/usr/local/bin/OpenRemote/OpenRemote-Controller-2.5.0"
-Dcatalina.base="/usr/local/bin/OpenRemote/OpenRemote-Controller-2.5.0"
-Djava.io.tmpdir="/usr/local/bin/OpenRemote/OpenRemote-Controller-2.5.0/temp"
-Dtomcat.server.console.log.level=OFF
-Dopenremote.controller.startup.log.level=INFO
-Dopenremote.controller.console.threshold=OFF
-Dopenremote.remote.command.service.uri=https://designer.openremote.com/ccs/rest/
-Dopenremote.device.discovery.service.uri=https://designer.openremote.com/dds/rest/
-Dopenremote.sync.service.uri=https://designer.openremote.com/beehive/rest/
-Dopenremote.controller.id=1
-Djava.library.path="/usr/local/bin/OpenRemote/OpenRemote-Controller-2.5.0/webapps/controller/WEB-INF/lib/native" "
-Djava.util.logging.config.file=/usr/local/bin/OpenRemote/OpenRemote-Controller-2.5.0/conf/logging.properties"
-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager
-classpath “:/usr/local/bin/OpenRemote/OpenRemote-Controller-2.5.0/bin/tomcat/bootstrap.jar” org.apache.catalina.startup.Bootstrap start ) | head -c 50000 >> “/usr/local/bin/OpenRemote/OpenRemote-Controller-2.5.0/logs/container/stderrout.log” 2>&1 &

Has somebody been able to get OR running as daemon on OS X?