- def set_vm_nic(self, temp_vm_file):
- with open(temp_vm_file) as f:
- vm_xml = etree.parse(f)
- interfaces = vm_xml.xpath('/domain/devices/interface')
+ def update_vm_template_file(self):
+ with open(self.temp_vm_file, "wc") as f:
+ self.vm_xml.write(f, pretty_print=True, xml_declaration=True)
+
+ def del_vm_nics(self):
+ interfaces = self.vm_xml.xpath('/domain/devices/interface')