ansible-personal/roles/common/handlers/main.yml
Alan Orth 0a92f3ae8f roles/common: Use systemd module instead of "service"
This was new in Ansible 2.2 but I didn't notice until now. All of our
servers are running distributions with systemd so let's just use this.
2017-11-05 00:27:44 +02:00

18 lines
405 B
YAML

---
# file: roles/common/handlers/main.yml
- name: restart iptables
service: name=iptables state=restarted
- name: restart iptables-persistent
service: name=iptables-persistent state=restarted
- name: reload sshd
systemd: name={{ sshd_service_name }} state=reloaded
- name: reload sysctl
command: sysctl -p /etc/sysctl.conf
- name: restart firewalld
systemd: name=firewalld state=restarted