network: when Gateway=_dhcp4, set several properties based on lease if they are not...
authorYu Watanabe <watanabe.yu+github@gmail.com>
Mon, 12 Oct 2020 06:52:02 +0000 (15:52 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Wed, 14 Oct 2020 22:06:23 +0000 (07:06 +0900)
commitc27abcf4fbd9d18f3a3b94453d6983ee10af1e4f
treecd158360054dff5644f733a89102972fceb8e59c
parent5bb80a46030902e636c72d850ff9aa97c8632f3f
network: when Gateway=_dhcp4, set several properties based on lease if they are not explicitly specified

Before this commit, event when Gateway=_dhcp4 or _ra is set, the
route was configured with 'protocol static', and other properties
specified by RouteTable=, RouteMTU=, or etc, were ignored.

This commit makes set the route protocol based on the protocol the
gateway address is obtained, and apply other settings if it is not
explicitly specified in the [Route] section.
src/network/networkd-dhcp4.c
src/network/networkd-ndisc.c
src/network/networkd-route.c
src/network/networkd-route.h
test/test-network/systemd-networkd-tests.py