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.
This commit is contained in:
2017-11-02 18:55:20 +02:00
parent 0e409792ca
commit 0a92f3ae8f
2 changed files with 4 additions and 4 deletions

View File

@ -8,10 +8,10 @@
service: name=iptables-persistent state=restarted
- name: reload sshd
service: name={{ sshd_service_name }} state=reloaded
systemd: name={{ sshd_service_name }} state=reloaded
- name: reload sysctl
command: sysctl -p /etc/sysctl.conf
- name: restart firewalld
service: name=firewalld state=restarted
systemd: name=firewalld state=restarted