[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v1 02/14] tests/vm: Debug mode shows ssh output.
From: |
Robert Foley |
Subject: |
[PATCH v1 02/14] tests/vm: Debug mode shows ssh output. |
Date: |
Wed, 5 Feb 2020 16:29:08 -0500 |
Add changes to tests/vm/basevm.py so that during debug mode we show ssh output.
Signed-off-by: Robert Foley <address@hidden>
Reviewed-by: Peter Puhov <address@hidden>
Reviewed-by: Alex Bennée <address@hidden>
---
tests/vm/basevm.py | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/tests/vm/basevm.py b/tests/vm/basevm.py
index ed5dd4f3d0..991115e44b 100755
--- a/tests/vm/basevm.py
+++ b/tests/vm/basevm.py
@@ -122,11 +122,16 @@ class BaseVM(object):
return fname
def _ssh_do(self, user, cmd, check):
- ssh_cmd = ["ssh", "-q", "-t",
+ ssh_cmd = ["ssh",
+ "-t",
"-o", "StrictHostKeyChecking=no",
"-o", "UserKnownHostsFile=" + os.devnull,
"-o", "ConnectTimeout=1",
"-p", self.ssh_port, "-i", self._ssh_key_file]
+ # If not in debug mode, set ssh to quiet mode to
+ # avoid printing the results of commands.
+ if not self.debug:
+ ssh_cmd.append("-q")
for var in self.envvars:
ssh_cmd += ['-o', "SendEnv=%s" % var ]
assert not isinstance(cmd, str)
--
2.17.1
- [PATCH v1 00/14] tests/vm: Add support for aarch64 VMs, Robert Foley, 2020/02/05
- [PATCH v1 01/14] tests/vm: use $(PYTHON) consistently, Robert Foley, 2020/02/05
- [PATCH v1 02/14] tests/vm: Debug mode shows ssh output.,
Robert Foley <=
- [PATCH v1 03/14] tests/vm: increased max timeout for vm boot., Robert Foley, 2020/02/05
- [PATCH v1 04/14] tests/vm: give wait_ssh() option to wait for root, Robert Foley, 2020/02/05
- [PATCH v1 05/14] tests/vm: Added gen_cloud_init_iso() to basevm.py, Robert Foley, 2020/02/05
- [PATCH v1 06/14] tests/vm: Add logging of console to file., Robert Foley, 2020/02/05