From: Rasjid W. <ra...@op...> - 2003-01-27 12:47:09
|
On Fri, 24 Jan 2003 3:55 am, Johannes Graumann wrote: > christian laubscher <christian@ti...> said: > >def main(): > > mycon=pyssh.Ssh('tiger','localhost','22') > > mycon.set_debuglevel(0) > > mycon.set_sshpath(pyssh.SSH_PATH) > > mycon.login() > > cmd='ps auxw | grep httpd | grep -v grep ; echo $?' > > C=mycon.sendcmd(cmd) > > print C > > mycon.close() > > > >main() > > That got me roling! Thanks! > > Another question (I know that this is bad style, but I'd like to do it > anyway): can I hand ssh the password as a variable? How? > > Another question (it never stops ... ;0): How do I do scp - I think > sourceforge sells pyssh als ssh AND scp wrapper? Ah. I must update the website some more. My appologies, but the website was put up by the original maintainer, who had grand plans for pyssh that never quite came to pass. I took on maintanence (essentially by re-writing pyssh) last year, but have only recently updated the website, and then only minimally (just enough to point people at the current version, and not the old one). So the short answer is that, no, it is currenly not a scp wapper, although I think it could be adapted to be so with fairly little work. Feel free to take on the task. ;-) > > ># ymmv ;-) > > ? Ymmv: Your miliage may vary. Cheers, Rasjid. -- Rasjid Wilcox Canberra, Australia (UTC +10 hrs) http://www.openminddev.net |