Add common roles from polyfloyd's playbookds
This commit is contained in:
parent
1332f49101
commit
e43ec3229f
23 changed files with 694 additions and 0 deletions
30
roles/common/handlers/main.yaml
Normal file
30
roles/common/handlers/main.yaml
Normal file
|
@ -0,0 +1,30 @@
|
|||
---
|
||||
- name: update grub
|
||||
command: update-grub
|
||||
|
||||
- name: reboot
|
||||
reboot:
|
||||
|
||||
- name: apt update
|
||||
apt:
|
||||
update_cache: true
|
||||
|
||||
- name: daemon reload
|
||||
systemd:
|
||||
daemon_reload: true
|
||||
|
||||
- name: reload sshd
|
||||
systemd:
|
||||
name: ssh
|
||||
state: reloaded
|
||||
|
||||
- name: reload nginx
|
||||
systemd:
|
||||
name: nginx
|
||||
state: reloaded
|
||||
|
||||
- name: persist iptables
|
||||
shell: "{{ item.c }}-save > /etc/iptables/rules.{{ item.ip }}"
|
||||
with_items:
|
||||
- { c: iptables, ip: v4 }
|
||||
- { c: ip6tables, ip: v6 }
|
Loading…
Add table
Add a link
Reference in a new issue