During IPv6 installation this script was generating an invalid mgmt_gw
value, due to an awk rule tuned for IPv4. This created an invalid
"gateway=1" in the ifupdown script, generating a parser error.
In a bonding setup with management as a vlan, the parsing error was
preventing the vlan interface over the ethernet port removal. The port
will be a slave on the bonding. Since the removal failed it cannot
add the vlan interface on top of the bonding interface.
The change uses the active controller floating value as a suitable
gateway, since at this stage the management network is the only
outside world option. If the value was not provided on API request
a valid IP is created (IPv4 or IPv6) to not generate parsing error.
For now there is no real case for the gateway to be used as all mgmt
traffic during kickstart and up to the first puppet manifest execution
is local, so in principle the gateway is just there for future use.
That is why it is not blocking installation.
Test Plan:
[PASS] Install AIO-DX (IPv4 and IPv6)
[PASS] Install Standard (IPv4 and IPv6)
Closes-Bug: 2070036
Change-Id: I4e76d878fecf589972bf93fdd75453a277c03d6a
Signed-off-by: Andre Kantek <andrefernandozanella.kantek@windriver.com>