summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'app-misc/openhab-bin/files/openhab.service')
-rw-r--r--app-misc/openhab-bin/files/openhab.service26
1 files changed, 26 insertions, 0 deletions
diff --git a/app-misc/openhab-bin/files/openhab.service b/app-misc/openhab-bin/files/openhab.service
new file mode 100644
index 000000000000..1a32a07bbc4d
--- /dev/null
+++ b/app-misc/openhab-bin/files/openhab.service
@@ -0,0 +1,26 @@
+[Unit]
+Description=openHAB - empowering the smart home
+Documentation=https://www.openhab.org/docs/
+Documentation=https://community.openhab.org
+Wants=network-online.target
+After=network-online.target
+
+[Service]
+EnvironmentFile=/etc/env.d/50openhab
+EnvironmentFile=-/etc/default/openhab
+
+User=openhab
+
+WorkingDirectory=/usr/share/openhab
+ExecStart=openhab daemon
+ExecStop=openhab stop
+
+SuccessExitStatus=0 143
+RestartSec=15
+Restart=on-failure
+TimeoutStopSec=120
+
+LimitNOFILE=102642
+
+[Install]
+WantedBy=multi-user.target