diff --git a/timmy/env.py b/timmy/env.py index b056173..4b79ea6 100644 --- a/timmy/env.py +++ b/timmy/env.py @@ -16,7 +16,7 @@ # under the License. project_name = 'timmy' -version = '1.15.1' +version = '1.15.2' if __name__ == '__main__': sys.exit(0) diff --git a/timmy/tools.py b/timmy/tools.py index 3b7f6bc..8236f56 100644 --- a/timmy/tools.py +++ b/timmy/tools.py @@ -258,9 +258,9 @@ def ssh_node(ip, command='', ssh_opts=None, env_vars=None, timeout=15, cmd = "%s < '%s'" % (cmd, inputfile) else: cmd = "%s'%s bash -s' < '%s'" % (bstr, prefix, filename) - logger.info("inputfile selected, cmd: %s" % cmd) - if outputfile is not None: - cmd = "%s > '%s'" % (cmd, outputfile) + if outputfile is not None: + cmd = "%s > '%s'" % (cmd, outputfile) + logger.info("cmd: %s" % cmd) cmd = ("input=\"$(cat | xxd -p)\"; trap 'kill $pid' 15; " + "trap 'kill $pid' 2; echo -n \"$input\" | xxd -r -p | " + cmd + ' &:; pid=$!; wait $!')