added disabling of ipv6
This commit is contained in:
parent
d1c990ee2f
commit
fced43fa95
1 changed files with 11 additions and 2 deletions
13
common.yml
13
common.yml
|
@ -151,13 +151,22 @@
|
||||||
group: root
|
group: root
|
||||||
mode: '0644'
|
mode: '0644'
|
||||||
|
|
||||||
# Set vm.swappiness to 5 in /etc/sysctl.conf
|
# Set vm.swappiness to 5 in /etc/sysctl.conf
|
||||||
- sysctl:
|
- name: "Set swappiness to zero in sysctl.conf"
|
||||||
|
sysctl:
|
||||||
name: vm.swappiness
|
name: vm.swappiness
|
||||||
value: '0'
|
value: '0'
|
||||||
state: present
|
state: present
|
||||||
|
reload: yes
|
||||||
sysctl_file: /etc/sysctl.conf
|
sysctl_file: /etc/sysctl.conf
|
||||||
|
|
||||||
|
- name: Disable IPv6 with sysctl
|
||||||
|
sysctl: name={{ item }} value=1 state=present reload=yes
|
||||||
|
with_items:
|
||||||
|
- net.ipv6.conf.all.disable_ipv6
|
||||||
|
- net.ipv6.conf.default.disable_ipv6
|
||||||
|
- net.ipv6.conf.lo.disable_ipv6
|
||||||
|
|
||||||
|
|
||||||
- name: "ssh_hardening"
|
- name: "ssh_hardening"
|
||||||
hosts: localhost
|
hosts: localhost
|
||||||
|
|
Loading…
Reference in a new issue