[pve-devel] [PATCH 2/3] LXCSetup::Redhat: ipv6 config

Wolfgang Bumiller w.bumiller at proxmox.com
Tue Jun 30 13:47:52 CEST 2015


According to their documentation both of these variables
take an IP[/prefix] notation, the gateway even has an
optional '%iface' suffix. So it should be possible to simply
take over the value content from the configuration directly.
---
 src/PVE/LXCSetup/Redhat.pm | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/PVE/LXCSetup/Redhat.pm b/src/PVE/LXCSetup/Redhat.pm
index ba29eb5..4d4e1d9 100644
--- a/src/PVE/LXCSetup/Redhat.pm
+++ b/src/PVE/LXCSetup/Redhat.pm
@@ -207,11 +207,11 @@ sub setup_network {
 		    $data .= "GATEWAY=$d->{gw}\n";
 		}
 	    }
-	    if (defined($d->{gw6})) {
-		die "implement me";
-	    }
 	    if (defined($d->{ip6})) {
-		die "implement me";
+		$data .= "IPV6ADDR=$d->{ip6}\n";
+	    }
+	    if (defined($d->{gw6})) {
+		$data .= "IPV6_DEFAULTGW=$d->{gw6}\n";
 	    }
 	    PVE::Tools::file_set_contents($filename, $data);
 	}
-- 
2.1.4




More information about the pve-devel mailing list