diff options
author | Adrian Likins <alikins@redhat.com> | 2007-09-21 16:22:51 -0400 |
---|---|---|
committer | Adrian Likins <alikins@redhat.com> | 2007-09-21 16:22:51 -0400 |
commit | d533633378be3d09376fd8b44b385e73e621ea52 (patch) | |
tree | 4468d894b6d8e6c293a797ea63a931102db51e9a | |
parent | 6d300c03206dd4cef3bd55e6370223d913e16638 (diff) | |
parent | 0d1ea605ec8d69b1cdf81c03fe0ec13336cb11ec (diff) | |
download | func-d533633378be3d09376fd8b44b385e73e621ea52.tar.gz func-d533633378be3d09376fd8b44b385e73e621ea52.tar.xz func-d533633378be3d09376fd8b44b385e73e621ea52.zip |
Merge branch 'master' of ssh://git.fedoraproject.org/git/hosted/func
-rw-r--r-- | client/test_func.py | 2 | ||||
-rwxr-xr-x | modules/virt.py | 10 |
2 files changed, 6 insertions, 6 deletions
diff --git a/client/test_func.py b/client/test_func.py index 19ec3af..281fb6d 100644 --- a/client/test_func.py +++ b/client/test_func.py @@ -22,7 +22,7 @@ if TEST_SERVICES: if TEST_VIRT: # example of using koan to install a virtual machine - # s.virt_install("mdehaan.rdu.redhat.com","fc7webserver",False) + #s.virt_install("mdehaan.rdu.redhat.com","profileX") # wait ... vms = s.virt_list_vms() diff --git a/modules/virt.py b/modules/virt.py index dc9a13a..319c2f3 100755 --- a/modules/virt.py +++ b/modules/virt.py @@ -53,7 +53,7 @@ class FuncLibvirtConnection(): conn = libvirt.open("qemu:///system") if not conn: - raise FuncException(comment="hypervisor connection failure") + raise codes.FuncException("hypervisor connection failure") self.conn = conn @@ -84,7 +84,7 @@ class FuncLibvirtConnection(): if vm.name() == vmid: return vm - raise FuncException(comment="virtual machine %s not found" % needle) + raise codes.FuncException("virtual machine %s not found" % needle) def shutdown(self, vmid): return self.find_vm(vmid).shutdown() @@ -171,10 +171,10 @@ class Virt(func_module.FuncModule): conn = self.get_conn() if conn is None: - raise FuncException(comment="no connection") + raise codes.FuncException("no connection") if not os.path.exists("/usr/bin/koan"): - raise FuncException(comment="no /usr/bin/koan") + raise codes.FuncException("no /usr/bin/koan") target = "profile" if system: target = "system" @@ -192,7 +192,7 @@ class Virt(func_module.FuncModule): if rc == 0: return 0 else: - raise FuncException(comment="koan returned %d" % rc) + raise codes.FuncException("koan returned %d" % rc) def shutdown(self, vmid): |