diff options
author | Marco Capitani <m.capitani@nextworks.it> | 2017-06-30 12:17:16 +0200 |
---|---|---|
committer | Marco Capitani <m.capitani@nextworks.it> | 2017-06-30 12:17:16 +0200 |
commit | 815839bf3cac2fcfd2d25a69395055397d55a8bb (patch) | |
tree | 128c5acaf009245b87c982ae7e85041c39afee98 /rumba/testbeds | |
parent | 50f0edfca9b552d332d250022e0d8c5fdaa531c7 (diff) | |
download | rumba-815839bf3cac2fcfd2d25a69395055397d55a8bb.tar.gz rumba-815839bf3cac2fcfd2d25a69395055397d55a8bb.zip |
ssh & model-storyboard: changed ssh API, added node.execute* methods
Diffstat (limited to 'rumba/testbeds')
-rw-r--r-- | rumba/testbeds/emulab.py | 2 | ||||
-rw-r--r-- | rumba/testbeds/jfed.py | 14 | ||||
-rw-r--r-- | rumba/testbeds/qemu.py | 2 |
3 files changed, 11 insertions, 7 deletions
diff --git a/rumba/testbeds/emulab.py b/rumba/testbeds/emulab.py index e7458bc..9b90e68 100644 --- a/rumba/testbeds/emulab.py +++ b/rumba/testbeds/emulab.py @@ -210,6 +210,8 @@ class Testbed(mod.Testbed): for node in experiment.nodes: node.ssh_config.hostname = self.full_name(node.name) + node.ssh_config.set_username(self.username) + node.ssh_config.set_password(self.password) cmd = 'cat /var/emulab/boot/topomap' topomap = ssh.execute_command(self, experiment.nodes[0].ssh_config, cmd) diff --git a/rumba/testbeds/jfed.py b/rumba/testbeds/jfed.py index e158048..ad6b98a 100644 --- a/rumba/testbeds/jfed.py +++ b/rumba/testbeds/jfed.py @@ -153,11 +153,13 @@ class Testbed(mod.Testbed): node.ssh_config.hostname = \ node.name + "." + self.exp_name + "." + \ auth_name_r + "." + self.auth_name - node.ssh_config.proxycommand = "ssh -i '" + self.cert_file + \ - "' -o StrictHostKeyChecking=no " + \ - self.username + \ - "@bastion.test.iminds.be nc " + \ - node.ssh_config.hostname + " 22" + node.ssh_config.proxy_command = "ssh -i '" + self.cert_file + \ + "' -o StrictHostKeyChecking=no " + \ + self.username + \ + "@bastion.test.iminds.be nc " + \ + node.ssh_config.hostname + " 22" + node.ssh_config.username = self.username + node.ssh_config.password = self.password subprocess.call(["java", "-jar", self.jfed_jar, "create", "-S", self.proj_name, "--rspec", @@ -172,8 +174,6 @@ class Testbed(mod.Testbed): rspec = xml.parse(self.manifest) xml_nodes = rspec.getElementsByTagName("node") - dir_path = os.path.dirname(os.path.abspath(__file__)) - # Complete details of the nodes after swapin logger.info("Sleeping for two seconds to avoid contacting jfed nodes " "too soon.") diff --git a/rumba/testbeds/qemu.py b/rumba/testbeds/qemu.py index 1d449dc..34458e2 100644 --- a/rumba/testbeds/qemu.py +++ b/rumba/testbeds/qemu.py @@ -255,6 +255,8 @@ class Testbed(mod.Testbed): vm['id'] = vmid node.ssh_config.hostname = "localhost" node.ssh_config.port = fwdp + node.ssh_config.username = self.username + node.ssh_config.password = self.password vars_dict = {'fwdp': fwdp, 'id': vmid, 'mac': mac, 'bzimage': self.bzimage, |