From a2a0d62ffe6852191b3f8aae5c565e8c18a8c2a8 Mon Sep 17 00:00:00 2001 From: Michael Ramsey Date: Sat, 25 Apr 2020 07:24:26 -0400 Subject: [PATCH] Fix command spacing --- plogical/backupUtilities.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plogical/backupUtilities.py b/plogical/backupUtilities.py index 9471fbc4b..886e0f67f 100755 --- a/plogical/backupUtilities.py +++ b/plogical/backupUtilities.py @@ -1090,7 +1090,7 @@ class backupUtilities: return [0, "377 Remote Server is not able to authenticate for transfer to initiate. [checkConnection]"] @staticmethod - def verifyHostKey(IPAddress): + def verifyHostKey(IPAddress, port='22', user='root'): try: backupUtilities.host_key_verification(IPAddress) @@ -1101,7 +1101,7 @@ class backupUtilities: expectation.append("continue connecting (yes/no)?") expectation.append("password:") - setupSSHKeys = pexpect.spawn("ssh cyberpanel@" + IPAddress, timeout=3) + setupSSHKeys = pexpect.spawn("ssh -p " + port + user + "@" + IPAddress, timeout=3) index = setupSSHKeys.expect(expectation)