SSH port for plugin call to log collector
Fixes the following error:
ERROR: execute_python_eval: __init__()
missing 1 required positional argument: 'port_ssh'
Changes:
- Added port variable argument
Tested:
- Ran chnages from sandbox.
Change-Id: I0e75b757022e3cbfdc06480fdc88af7024fa4dd8
Signed-off-by: George Keishing <gkeishin@in.ibm.com>
diff --git a/ffdc/plugins/ssh_execution.py b/ffdc/plugins/ssh_execution.py
index fd76583..f6aad88 100644
--- a/ffdc/plugins/ssh_execution.py
+++ b/ffdc/plugins/ssh_execution.py
@@ -20,7 +20,7 @@
def ssh_execute_cmd(
- hostname, username, password, command, timeout=60, type=None
+ hostname, username, password, port_ssh, command, timeout=60, type=None
):
r"""
Description of argument(s):
@@ -28,11 +28,12 @@
hostname Name/IP of the remote (targeting) host
username User on the remote host with access to FFCD files
password Password for user on remote host
+ port_ssh SSH port value. By default 22.
command Command to run on remote host
timeout Time, in second, to wait for command completion
type Data type return as list or others.
"""
- ssh_remoteclient = SSHRemoteclient(hostname, username, password)
+ ssh_remoteclient = SSHRemoteclient(hostname, username, password, port_ssh)
cmd_exit_code = 0
err = ""