library/roles/ubuntu-deb-general/tasks/manage-ipv6-status.yml: Simplify the ipv6 enabling/disabling.
This commit is contained in:
parent
cf2128c092
commit
ca2bbc03cd
|
@ -4,12 +4,25 @@
|
|||
when: is_not_debian_less_than_6
|
||||
tags: ipv6
|
||||
|
||||
- name: Manage the in kernel ipv6 support
|
||||
sysctl: name={{ item }} value={{ ipv6_sysctl_value }} sysctl_file={{ ipv6_sysctl_file }} reload=yes state=present
|
||||
- name: Disable the in kernel ipv6 support
|
||||
sysctl: name={{ item }} value=1 sysctl_file={{ ipv6_sysctl_file }} reload=yes state=present
|
||||
with_items:
|
||||
- net.ipv6.conf.all.disable_ipv6
|
||||
- net.ipv6.conf.default.disable_ipv6
|
||||
- net.ipv6.conf.lo.disable_ipv6
|
||||
when: is_not_debian_less_than_6
|
||||
when:
|
||||
- is_not_debian_less_than_6
|
||||
- disable_ipv6
|
||||
tags: ipv6
|
||||
|
||||
- name: enable the in kernel ipv6 support
|
||||
sysctl: name={{ item }} value=0 sysctl_file={{ ipv6_sysctl_file }} reload=yes state=present
|
||||
with_items:
|
||||
- net.ipv6.conf.all.disable_ipv6
|
||||
- net.ipv6.conf.default.disable_ipv6
|
||||
- net.ipv6.conf.lo.disable_ipv6
|
||||
when:
|
||||
- is_not_debian_less_than_6
|
||||
- not disable_ipv6
|
||||
tags: ipv6
|
||||
|
||||
|
|
Loading…
Reference in New Issue