Restart networking when nftables is restarted
This commit is contained in:
parent
18263b3556
commit
1b291adb38
@ -4,9 +4,9 @@ iface br0 inet static
|
|||||||
|
|
||||||
post-up /usr/local/sbin/post-up-$IFACE.nft
|
post-up /usr/local/sbin/post-up-$IFACE.nft
|
||||||
post-up ip rule add dev $IFACE table 66
|
post-up ip rule add dev $IFACE table 66
|
||||||
post-up ip route add {{ subnet }} dev {{ ethx }} table 66
|
post-up ip rule add dev $IFACE to {{ subnet }} table main priority 1
|
||||||
|
|
||||||
pre-down ip route del {{ subnet }} dev {{ ethx }} table 66
|
pre-down ip rule del dev $IFACE to {{ subnet }} table main priority 1
|
||||||
pre-down ip rule del dev $IFACE table 66
|
pre-down ip rule del dev $IFACE table 66
|
||||||
pre-down /usr/local/sbin/pre-down-$IFACE.nft
|
pre-down /usr/local/sbin/pre-down-$IFACE.nft
|
||||||
|
|
||||||
|
@ -19,5 +19,13 @@
|
|||||||
systemd:
|
systemd:
|
||||||
name: nftables
|
name: nftables
|
||||||
state: restarted
|
state: restarted
|
||||||
|
register: nftables_restart
|
||||||
when:
|
when:
|
||||||
nftables_conf is changed
|
nftables_conf is changed
|
||||||
|
|
||||||
|
- name: Restart networking
|
||||||
|
systemd:
|
||||||
|
name: networking
|
||||||
|
state: restarted
|
||||||
|
when:
|
||||||
|
nftables_restart is changed
|
||||||
|
Loading…
Reference in New Issue
Block a user