From 7cad29ec72c8765cd439e12a251458a71629bc25 Mon Sep 17 00:00:00 2001 From: Luke Hoersten Date: Thu, 1 Mar 2018 17:14:13 -0600 Subject: Broke out separate hap-door role from hap-nodejs. --- roles/hap-door/tasks/main.yaml | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 roles/hap-door/tasks/main.yaml (limited to 'roles/hap-door/tasks') diff --git a/roles/hap-door/tasks/main.yaml b/roles/hap-door/tasks/main.yaml new file mode 100644 index 0000000..7e1669f --- /dev/null +++ b/roles/hap-door/tasks/main.yaml @@ -0,0 +1,38 @@ +--- + +- name: install python3 apt packages + become: yes + apt: name="python3" + notify: restart hap-nodejs service + +- name: install python-shell npm packages + become: yes + npm: name="python-shell" global="yes" + notify: restart hap-nodejs service + +- name: install door accessory + become: yes + copy: + src: "../../../src/Door_accessory.js" + dest: "{{hap_dest}}/accessories/Door_accessory.js" + owner: "{{hap_user}}" + group: "{{hap_user}}" + notify: restart hap-nodejs service + +- name: create python dir + become: yes + file: + path: "{{hap_dest}}/python" + state: "directory" + owner: "{{hap_user}}" + group: "{{hap_user}}" + +- name: install doord.py + become: yes + copy: + src: "../../../src/doord.py" + dest: "{{hap_dest}}/python/doord.py" + owner: "{{hap_user}}" + group: "{{hap_user}}" + mode: "0755" + notify: restart hap-nodejs service -- cgit v1.2.3