Tommi Virtanen
be28e5bfd8
Refactor to extract shell quoting into utility function.
2011-05-24 13:27:39 -07:00
Tommi Virtanen
1a459dd7fe
Depend on Paramiko 1.7.7 or newer to be able to read modern OpenSSH keys.
2011-05-24 13:16:47 -07:00
Tommi Virtanen
37c94af8a7
Pyflakes cleanup.
2011-05-24 13:12:21 -07:00
Tommi Virtanen
5d5b179565
Add a utility function run.wait to wait for processes to exit.
2011-05-24 13:07:24 -07:00
Tommi Virtanen
073a4bbc18
Paramiko ChannelFile.close() didn't actually close the remote stdin.
...
Add a wrapper that does the calls shutdown on the channel itself,
to actually cause EOF. Add integration test using remote cat.
Move shuffling stdout bytes to background, so run.run returns before
seeing EOF on stdout, and thus actually making the stdin useful.
Similarly, don't wait for EOF on stderr before returning from run.run.
2011-05-24 13:06:00 -07:00
Tommi Virtanen
6dd4774f0a
Log debug info of commands actually executed.
2011-05-24 13:01:46 -07:00
Tommi Virtanen
9c42fe6bbf
Cleanup dead code.
2011-05-24 13:01:03 -07:00
Tommi Virtanen
f10668f53f
Allow easy writing to stdin of remote processes.
2011-05-24 13:00:44 -07:00
Tommi Virtanen
f8f6bed680
Add run.run option wait, this will make handling stdin easier soon.
2011-05-19 15:10:04 -07:00
Tommi Virtanen
93c2e17c01
Return a structured result from run.run, to make capturing stdout/stderr easier.
2011-05-19 13:47:09 -07:00
Tommi Virtanen
9a5c959bc8
Add integration tests for signals and connection loss.
2011-05-19 13:27:32 -07:00
Tommi Virtanen
df84f4e052
Check for errors on remote commands.
2011-05-19 13:05:14 -07:00
Tommi Virtanen
87d7192c89
Add setup.py, install in devel mode into virtualenv.
2011-05-19 12:17:28 -07:00
Tommi Virtanen
492fa48893
Don't close file after copying stdout/stderr to it.
...
If a caller uses StringIO to capture the output, they
cannot call .getvalue() after the close.
This also lets you collect multiple command outputs
into the same file.
2011-05-19 12:16:43 -07:00
Tommi Virtanen
37df5b1c39
Refactor remote running to support more use cases.
2011-05-19 10:20:32 -07:00
Tommi Virtanen
5bfcec265b
Add debug logging to monkeypatching.
2011-05-19 10:19:16 -07:00
Tommi Virtanen
1ed70d78d8
Silence paramiko transport logging.
2011-05-19 10:18:57 -07:00
Tommi Virtanen
b397eb5d91
Silence a Paramiko crypto deprecation.
2011-05-19 10:17:51 -07:00
Tommi Virtanen
85a28a23da
Make monkeypatching respect order.
2011-05-19 10:17:03 -07:00
Tommi Virtanen
0535e4df08
Initial import
2011-05-18 14:46:49 -07:00