24 lines
422 B
YAML
24 lines
422 B
YAML
- name: Install nftables
|
|
apt:
|
|
name: nftables
|
|
|
|
- name: Configure nftables
|
|
template:
|
|
src: ./filesystem/common/etc/nftables.conf.j2
|
|
dest: /etc/nftables.conf
|
|
mode: 0755
|
|
register: nftables_conf
|
|
|
|
- name: Enable/start nftables
|
|
systemd:
|
|
name: nftables
|
|
state: started
|
|
enabled: yes
|
|
|
|
- name: Restart nftables
|
|
systemd:
|
|
name: nftables
|
|
state: restarted
|
|
when:
|
|
nftables_conf is changed
|