feat(ssh): support runit for service reloading

This commit is contained in:
Jan Christian Grünhage 2023-02-19 12:47:00 +01:00
parent d0d73b9327
commit 35bc21a0c0
No known key found for this signature in database
GPG key ID: EEC1170CE56FA2ED

View file

@ -1,5 +1,14 @@
---
- name: "reload sshd"
- name: "Reload sshd using systemd"
ansible.builtin.systemd:
name: "sshd"
state: "reloaded"
when: "ansible_service_mgr == 'systemd'"
listen: "reload sshd"
- name: "Reload sshd using runit"
community.general.runit:
name: "sshd"
state: "reloaded"
when: "ansible_service_mgr == 'runit'"
listen: "reload sshd"