- name: Configure IPv4 and IPv6 packet forwarding ansible.builtin.sysctl: name: '{{ item }}' value: '1' sysctl_set: true loop: - net.ipv4.ip_forward - net.ipv4.conf.all.forwarding - net.ipv6.conf.all.forwarding