Flush entire interface rather than just routes

This patch changes the flush routes handler to flush the entire
interface config from the interface. This is needed because
systemd-networkd does not restore the route of non-DHCP interfaces
when flushing routes and restarting systemd-networks.

Change-Id: I17748b0dd2307fd9bee705140c67883140090298
Signed-off-by: Major Hayden <major@mhtx.net>
This commit is contained in:
Major Hayden 2018-03-06 16:00:24 -06:00 committed by Kevin Carter (cloudnull)
parent f89140f478
commit c36980380e
1 changed files with 5 additions and 2 deletions

View File

@ -48,8 +48,11 @@
retries: 3
listen: Lxc container restart
- name: Flush routes
command: "ip route flush table main"
- name: Flush addresses
command: "ip addr flush {{ item.value.interface }}"
with_dict: "{{ lxc_container_networks_combined }}"
when:
- item.value.interface is defined
listen: Restart networkd
- name: Restart systemd-networkd