Inspired by
this post, I am planning to migrate my openHAB installation from my ubuntu HTPC to my QNAP NAS.
So I create a QPKG for openHAB for easier installation. :)
Java is required.
Install JRE via the App Center first.
Then download the openHAB-package, install it manually via the App Center on the QNAP-Admin-Webinterface and enable it.

The openHAB webserver should be ready on Port 8082 and 8443.
Telnet port 5555.
Depending on your QNAP-Model and your RAID-Level the package gets installed in the following directory.
/share/MD0_DATA/.qpkg/openHAB/
To change the ports edit openHAB.sh and dis-/enable the service in the App Center.
Or you can use the following command via command line.
/share/MD0_DATA/.qpkg/openHAB/openHAB.sh restart
You can also use the parameters start, stop, status, startdebug and forcestart.
The package just contains the runtime of openHAB 1.5.
You need to add the demo-files or your own configs and addons manually.
Tested on QNAP TS-859 and TS-239 Pro II.
Firmware 4.0.7.
Disclaimer:
This is my first QPKG and first init-script (openHAB.sh)
There might be bugs.
In case you find anything, let me know.
I donw#t know wich QNAP-Models and firmware-versions are compatible.
I don't promise to update the package regularly, because I don't know yet if I will run openHAB on my QNAP for good.