homeserver/roles/mgrote.fileserver_smb/handlers/main.yml

14 lines
427 B
YAML
Raw Normal View History

2021-02-20 15:58:23 +01:00
- name: restart_smbd
2020-08-18 11:57:53 +02:00
become: yes
systemd:
name: smbd
enabled: yes
state: restarted
- name: set_samba_passwords
become: yes
shell: "printf '{{ item.password }}\n{{ item.password }}\n' | smbpasswd -a {{ item.name }}" # noqa 306 301 #pipefail: https://blog.christophersmart.com/2019/09/28/using-pipefail-with-shell-module-in-ansible/
with_items:
2021-02-20 15:58:23 +01:00
- "{{ smb_users }}"
2020-08-18 11:57:53 +02:00
no_log: True