Remove separate check for Xen

Module checked for Xen-based system, however since 'xen:///' URI support
exists in 'libvirt', we should use it explicitly instead.
This commit is contained in:
Maciej Delmanowski 2015-07-25 18:21:10 +02:00
parent 1fd1460d2f
commit 055a31ba07

View file

@ -202,13 +202,7 @@ class LibvirtConnection(object):
self.module = module self.module = module
cmd = "uname -r" conn = libvirt.open(uri)
rc, stdout, stderr = self.module.run_command(cmd)
if "xen" in stdout:
conn = libvirt.open(None)
else:
conn = libvirt.open(uri)
if not conn: if not conn:
raise Exception("hypervisor connection failure") raise Exception("hypervisor connection failure")