Merge remote-tracking branch 'origin/master'

This commit is contained in:
Jeremy committed 2014-12-09 19:17:53 -07:00
commit acb5103119
9 files changed
+103 -80

No files matched your search

+1 -1
View File
@@ -83,6 +83,7 @@ class DeadMan(IModule):
cmd.append("--file")
cmd.append("%s" % (self._heartbeat_file))
cmd.append("--background")
cmd.append("--debug")
log.info("Deadman: Running command: %s"%(cmd))
process = subprocess.Popen(cmd, stderr=subprocess.STDOUT, shell=False)
@@ -94,7 +95,6 @@ class DeadMan(IModule):
"""
cmd = []
cmd.append("gns3dms")
cmd.append("-k")
log.info("Deadman: Running command: %s"%(cmd))
@@ -760,7 +760,6 @@ class VM(object):
if was_auto_started:
router.stop()
validated_idlepc = "0x0"
response = {"id": router.id,
"logs": logs,
"idlepc": validated_idlepc}
+23
View File
@@ -761,6 +761,29 @@ class QemuVM(object):
log.debug("Download of {} complete.".format(src))
self.hdb_disk_image = dst
if self.initrd != "":
_, filename = ntpath.split(self.initrd)
src = '{}/{}'.format(self.cloud_path, filename)
dst = os.path.join(self.working_dir, filename)
if not os.path.isfile(dst):
cloud_settings = Config.instance().cloud_settings()
provider = get_provider(cloud_settings)
log.debug("Downloading file from {} to {}...".format(src, dst))
provider.download_file(src, dst)
log.debug("Download of {} complete.".format(src))
self.initrd = dst
if self.kernel_image != "":
_, filename = ntpath.split(self.kernel_image)
src = '{}/{}'.format(self.cloud_path, filename)
dst = os.path.join(self.working_dir, filename)
if not os.path.isfile(dst):
cloud_settings = Config.instance().cloud_settings()
provider = get_provider(cloud_settings)
log.debug("Downloading file from {} to {}...".format(src, dst))
provider.download_file(src, dst)
log.debug("Download of {} complete.".format(src))
self.kernel_image = dst
self._command = self._build_command()
try:
log.info("starting QEMU: {}".format(self._command))