src.nth.io/

summaryrefslogtreecommitdiff
path: root/roles/hap-nodejs/templates/hap-nodejs.service.j2
diff options
context:
space:
mode:
authorLuke Hoersten <[email protected]>2018-01-19 11:48:25 -0600
committerLuke Hoersten <[email protected]>2018-01-19 11:48:25 -0600
commit5f6b0c0e6e2ea3621cb0033b9f5498372c89db74 (patch)
treecfade4f68d242333f20d8d5b44906f6bb2b94315 /roles/hap-nodejs/templates/hap-nodejs.service.j2
Initial public commit.
Diffstat (limited to 'roles/hap-nodejs/templates/hap-nodejs.service.j2')
-rw-r--r--roles/hap-nodejs/templates/hap-nodejs.service.j216
1 files changed, 16 insertions, 0 deletions
diff --git a/roles/hap-nodejs/templates/hap-nodejs.service.j2 b/roles/hap-nodejs/templates/hap-nodejs.service.j2
new file mode 100644
index 0000000..f657555
--- /dev/null
+++ b/roles/hap-nodejs/templates/hap-nodejs.service.j2
@@ -0,0 +1,16 @@
+# {{ansible_managed}}
+
+[Unit]
+Description=HAP-NodeJS
+
+[Service]
+User={{hap_user}}
+Group={{hap_user}}
+Restart=always
+RestartSec={{hap_restart_sec}}
+
+WorkingDirectory={{hap_dest}}
+ExecStart=/usr/bin/node {{hap_dest}}/Core.js
+
+[Install]
+WantedBy=default.target