xoxys.mosquitto/tasks/config.yml

18 lines
469 B
YAML
Raw Normal View History

2017-12-18 08:52:02 +00:00
---
2018-11-04 23:31:54 +00:00
- block:
- name: Copy passwd file to '{{ mosquitto_passwd_path }}'
template:
src: "etc/mosquitto/passwd.j2"
dest: "{{ mosquitto_passwd_path }}"
owner: root
group: root
mode: 0600
register: __mosquitto_passwd
2017-12-18 08:52:02 +00:00
2018-11-04 23:31:54 +00:00
- name: Hash passwd file
shell: "mosquitto_passwd -U {{ mosquitto_passwd_path }}"
notify: __mosquitto_restart
when: __mosquitto_passwd.changed
become: True
become_user: root