X-Git-Url: https://code.grnet.gr/git/ganeti-local/blobdiff_plain/a5ad5e58ebf7bfbe712b809cb0ea6283b75d6718..383477e9c27967731bbe871d266b309dbe4ac43d:/lib/ovf.py diff --git a/lib/ovf.py b/lib/ovf.py index dc58133..dc75816 100644 --- a/lib/ovf.py +++ b/lib/ovf.py @@ -537,7 +537,7 @@ class OVFReader(object): GANETI_SCHEMA) ganeti_data["link"] = network_ganeti_data.findtext("{%s}Link" % GANETI_SCHEMA) - ganeti_data["network"] = network_ganeti_data.findtext("{%s}Network" % + ganeti_data["network"] = network_ganeti_data.findtext("{%s}Net" % GANETI_SCHEMA) mac_data = None if network_data: @@ -760,7 +760,7 @@ class OVFWriter(object): SubElementText(nic, "gnt:MACAddress", network["mac"]) SubElementText(nic, "gnt:IPAddress", network["ip"]) SubElementText(nic, "gnt:Link", network["link"]) - SubElementText(nic, "gnt:Network", network["network"]) + SubElementText(nic, "gnt:Net", network["network"]) def SaveVirtualSystemData(self, name, vcpus, memory): """Convert virtual system information to OVF sections. @@ -1665,7 +1665,8 @@ class OVFExporter(Converter): counter = 0 while True: data_link = \ - self.config_parser.get(constants.INISECT_INS, "nic%s_network" % counter) + self.config_parser.get(constants.INISECT_INS, + "nic%s_link" % counter) if data_link is None: break results.append({ @@ -1675,9 +1676,9 @@ class OVFExporter(Converter): "nic%s_mac" % counter), "ip": self.config_parser.get(constants.INISECT_INS, "nic%s_ip" % counter), - "link": self.config_parser.get(constants.INISECT_INS, - "nic%s_link" % counter), - "network": data_link, + "network": self.config_parser.get(constants.INISECT_INS, + "nic%s_network" % counter), + "link": data_link, }) if results[counter]["mode"] not in constants.NIC_VALID_MODES: raise errors.OpPrereqError("Network mode %s not recognized"