mirror of
https://gitee.com/jack_whh/ssh-scp-ssh-pipelines.git
synced 2026-03-10 06:52:55 +08:00
print err, out
This commit is contained in:
8
app.py
8
app.py
@@ -82,9 +82,13 @@ def ssh_process(ssh, input_ssh):
|
|||||||
err = "".join(stderr.readlines())
|
err = "".join(stderr.readlines())
|
||||||
err = err.strip() if err is not None else None
|
err = err.strip() if err is not None else None
|
||||||
if err:
|
if err:
|
||||||
raise Exception(f"SSH failed:\n{err}")
|
print(f"Error: \n{err}")
|
||||||
|
|
||||||
|
out = "".join(stdout.readlines())
|
||||||
|
out = out.strip() if out is not None else None
|
||||||
|
if out:
|
||||||
|
print(f"Success: \n{out}")
|
||||||
|
|
||||||
print("".join(stdout.readlines()))
|
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user