
# HG changeset patch # User Sharad Mishra <snmishra@us.ibm.com> # Date 1259799202 28800 # Node ID 75243e330ed72b9d57516019ef9b185960503f17 # Parent 45c6da8ca664a61a727b0c0d1811c4337efb53b0 [TEST] Changes to vxml for IPv6 Support Signed-off-by: Sharad Mishra <snmishra@us.ibm.com> diff -r 45c6da8ca664 -r 75243e330ed7 suites/libvirt-cim/lib/XenKvmLib/vxml.py --- a/suites/libvirt-cim/lib/XenKvmLib/vxml.py Tue Dec 01 16:08:15 2009 -0800 +++ b/suites/libvirt-cim/lib/XenKvmLib/vxml.py Wed Dec 02 16:13:22 2009 -0800 @@ -569,7 +569,7 @@ def __init__(self, virt, dom_name, uuid, pae, acpi, apic, disk_dev, disk_source, net_type, net_name, net_mac, vcpus, mem, mem_allocunits, emu_type, grstype, ip, - port_num, kmap, irstype, btype, vnc_passwd): + IsIPv6Only, port_num, kmap, irstype, btype, vnc_passwd): self.virt = virt self.domain_name = dom_name self.err_rc = None @@ -591,6 +591,7 @@ dom_name, emu_type) self.gasd = vsms.get_gasd_class(virt)(name=dom_name, res_sub_type=grstype, ip=ip, + ipv6=IsIPv6Only, lport=port_num, keymap=kmap, vnc_passwd=vnc_passwd) self.masd = vsms.get_masd_class(virt)(megabytes=mem, @@ -813,7 +814,8 @@ disk=const.Xen_default_disk_dev, ntype=const.default_net_type, net_name=const.default_network_name, - emu_type=None, grstype="vnc", address="127.0.0.1", + emu_type=None, grstype="vnc", address=None, + IsIPv6Only=True, port_num='-1', keymap="en-us", irstype="mouse", btype="xen", vnc_passwd=None): if not (os.path.exists(const.Xen_kernel_path) \ @@ -828,7 +830,8 @@ VirtCIM.__init__(self, 'Xen', test_dom, uuid, pae, acpi, apic, disk, disk_file_path, ntype, net_name, mac, vcpus, mem, mem_allocunits, emu_type, grstype, address, - port_num, keymap, irstype, btype, vnc_passwd) + IsIPv6Only, port_num, keymap, irstype, btype, + vnc_passwd) def _os(self, os_kernel, os_initrd): os = self.get_node('/domain/os') @@ -882,7 +885,8 @@ disk=const.KVM_default_disk_dev, ntype=const.default_net_type, net_name=const.default_network_name, - emu_type=None, grstype="vnc", address="127.0.0.1", + emu_type=None, grstype="vnc", address=None, + IsIPv6Only=True, port_num='-1', keymap="en-us", irstype="mouse", btype="ps2", vnc_passwd=None): if not os.path.exists(disk_file_path): @@ -892,7 +896,8 @@ VirtCIM.__init__(self, 'KVM', test_dom, uuid, pae, acpi, apic, disk, disk_file_path, ntype, net_name, mac, vcpus, mem, mem_allocunits, emu_type, grstype, address, - port_num, keymap, irstype, btype, vnc_passwd) + IsIPv6Only, port_num, keymap, irstype, btype, + vnc_passwd) self._os() self._devices(const.KVM_default_emulator, ntype, disk_file_path, disk, mac, net_name) @@ -942,7 +947,8 @@ ntype=const.default_net_type, net_name=const.default_network_name, emu_type=None, grstype="vnc", - address="127.0.0.1", port_num='-1', keymap="en-us", + address=None, IsIPv6Only=True, port_num='-1', + keymap="en-us", irstype="mouse", btype="ps2", vnc_passwd=None): if not os.path.exists(disk_file_path): logger.error('Error: Disk image does not exist') @@ -950,7 +956,8 @@ VirtXML.__init__(self, 'xenfv', test_dom, set_uuid(), mem, vcpus) VirtCIM.__init__(self, 'XenFV', test_dom, disk, uuid, pae, acpi, apic, disk_file_path, ntype, net_name, mac, vcpus, mem, - mem_allocunits, emu_type, grstype, address, port_num, + mem_allocunits, emu_type, grstype, address, + IsIPv6Only, port_num, keymap, irstype, btype, vnc_passwd) self._os(const.XenFV_default_loader) self._devices(const.XenFV_default_emulator, @@ -993,13 +1000,15 @@ ntype=const.default_net_type, net_name=const.default_network_name, tty=const.LXC_default_tty, grstype="vnc", - address="127.0.0.1", port_num='-1', keymap="en-us", + address=None, IsIPv6Only=True, port_num='-1', + keymap="en-us", irstype="mouse", btype="usb", vnc_passwd=None): VirtXML.__init__(self, 'lxc', test_dom, set_uuid(), mem, vcpus) VirtCIM.__init__(self, 'LXC', test_dom, uuid, const.LXC_default_mp, const.LXC_default_source, ntype, net_name, mac, vcpus, mem, const.default_mallocunits, None, grstype, - address, port_num, keymap, irstype, btype, vnc_passwd) + address, IsIPv6Only, port_num, keymap, irstype, + btype, vnc_passwd) self._os(const.LXC_init_path) self._devices(const.LXC_default_emulator, mac, ntype, net_name, const.LXC_default_tty) self.create_lxc_file(CIM_IP, const.LXC_init_path)