Re: [libvirt] SSH URIs invoking askpass + sudo don't play well together

2011-07-25 Thread Daniel P. Berrange
On Fri, Jul 22, 2011 at 04:38:20PM -0400, Cole Robinson wrote: > $ cat test.py > import os > import sys > import libvirt > > def drop_tty(): > if os.fork() != 0: > os._exit(0) > os.setsid() > > host = sys.argv[1] > > # Need to drop controlling tty otherwise SSH won't call askpass

[libvirt] SSH URIs invoking askpass + sudo don't play well together

2011-07-22 Thread Cole Robinson
$ cat test.py import os import sys import libvirt def drop_tty(): if os.fork() != 0: os._exit(0) os.setsid() host = sys.argv[1] # Need to drop controlling tty otherwise SSH won't call askpass drop_tty() libvirt.open("qemu+ssh://root@%s/system" % host) $ python test.py localhost