aboutsummaryrefslogtreecommitdiff
path: root/rumba/ssh_support.py
diff options
context:
space:
mode:
authorMarco Capitani <m.capitani@nextworks.it>2017-07-28 11:57:20 +0200
committerMarco Capitani <m.capitani@nextworks.it>2017-07-28 11:57:20 +0200
commit7dc3b5086d4c1d19c9ef315369f3fd7c4dd2889e (patch)
treeb6cddc451fc182e0bd3384805f4ae705375f043b /rumba/ssh_support.py
parent357fd2481ddb2a7b07eab9a98b4ab3b2d8a0b307 (diff)
downloadrumba-7dc3b5086d4c1d19c9ef315369f3fd7c4dd2889e.tar.gz
rumba-7dc3b5086d4c1d19c9ef315369f3fd7c4dd2889e.zip
Model & ssh: ssh-related methods renaming
Diffstat (limited to 'rumba/ssh_support.py')
-rw-r--r--rumba/ssh_support.py14
1 files changed, 6 insertions, 8 deletions
diff --git a/rumba/ssh_support.py b/rumba/ssh_support.py
index e785f33..53d81a1 100644
--- a/rumba/ssh_support.py
+++ b/rumba/ssh_support.py
@@ -150,7 +150,7 @@ def execute_command(testbed, ssh_config, command, time_out=3):
return o
-def copy_file_to_testbed(testbed, ssh_config, text, file_name):
+def write_text_to_file(testbed, ssh_config, text, file_name):
"""
Write a string to a given remote file.
Overwrite the complete file if it already exists!
@@ -193,10 +193,9 @@ def copy_file_to_testbed(testbed, ssh_config, text, file_name):
logger.error(str(e))
-def copy_paths_to_testbed(testbed, ssh_config, paths, destination):
+def copy_files_to_testbed(testbed, ssh_config, paths, destination):
"""
- Write a string to a given remote file.
- Overwrite the complete file if it already exists!
+ Copies local files to a remote node.
@param testbed: testbed info
@param ssh_config: ssh config of the node
@@ -237,17 +236,16 @@ def copy_paths_to_testbed(testbed, ssh_config, paths, destination):
logger.error(str(e))
-def copy_path_to_testbed(testbed, ssh_config, path, destination):
+def copy_file_to_testbed(testbed, ssh_config, path, destination):
"""
- Write a string to a given remote file.
- Overwrite the complete file if it already exists!
+ Copies a local file to a remote node.
@param testbed: testbed info
@param ssh_config: ssh config of the node
@param path: source path (local)
@param destination: destination folder name (remote)
"""
- copy_paths_to_testbed(testbed, ssh_config, [path], destination)
+ copy_files_to_testbed(testbed, ssh_config, [path], destination)
def setup_vlan(testbed, node, vlan_id, int_name):