partially revert 4efb58a - unquote configdrive2 ips

configdrive2 uses /etc/network/interfaces style config instead of the
official yaml one. this does not allow quoting of the ip addresses.

Tested with Windows Server 2016.

Signed-off-by: Mira Limbeck <m.limbeck@proxmox.com>
This commit is contained in:
Mira Limbeck 2019-03-25 12:34:44 +01:00 committed by Thomas Lamprecht
parent 272db0fb64
commit 6f3999e0f5

View File

@ -174,9 +174,9 @@ sub configdrive2_network {
} else {
my ($addr, $mask) = split_ip4($net->{ip});
$content .= "iface $id inet static\n";
$content .= " address '$addr'\n";
$content .= " netmask '$mask'\n";
$content .= " gateway '$net->{gw}'\n" if $net->{gw};
$content .= " address $addr\n";
$content .= " netmask $mask\n";
$content .= " gateway $net->{gw}\n" if $net->{gw};
}
}
if ($net->{ip6}) {
@ -185,9 +185,9 @@ sub configdrive2_network {
} else {
my ($addr, $mask) = split('/', $net->{ip6});
$content .= "iface $id inet6 static\n";
$content .= " address '$addr'\n";
$content .= " netmask '$mask'\n";
$content .= " gateway '$net->{gw6}'\n" if $net->{gw6};
$content .= " address $addr\n";
$content .= " netmask $mask\n";
$content .= " gateway $net->{gw6}\n" if $net->{gw6};
}
}
}