Fix for multiple interfaces per slice
authorAndy Bavier <acb@cs.princeton.edu>
Wed, 2 May 2012 18:47:04 +0000 (14:47 -0400)
committerAndy Bavier <acb@cs.princeton.edu>
Wed, 2 May 2012 18:47:04 +0000 (14:47 -0400)
M-Lab wants an IPv4 and IPv6 address assigned per slice. When more than one interface is added to a slice, the interface/X/ip argument gets filled out correctly but the slice will not start because the 'nodev' option is missing.

python/vserver.py

index 4724311..8f4488b 100644 (file)
@@ -255,6 +255,7 @@ class VServer:
         i = 0
         for a in addresses.split(","):
             self.config.update("interfaces/%d/ip" % i, a)
+            self.config.update("interfaces/%d/nodev" % i, "")
             i += 1
         while self.config.unset("interfaces/%d/ip" % i):
             i += 1