Skip to content
This repository has been archived by the owner on Sep 20, 2018. It is now read-only.

unable to do a pseudo-tty to Native SSH client #46

Open
alfredodeza opened this issue Aug 23, 2013 · 4 comments
Open

unable to do a pseudo-tty to Native SSH client #46

alfredodeza opened this issue Aug 23, 2013 · 4 comments

Comments

@alfredodeza
Copy link
Contributor

I'm seeing some issues with newer SSH clients where the configuration is set to disallow sudo in non-tty environments, and given the fact that our tool requires sudo for pretty much all of the remote commands we get a problem where users simply cannot use our tool unless they change their SSH configurations.

ssh allows the usage of -t as a flag to override this, but we are not able to pass that flag to the NativeSSHClient because the **kwargs in the client ignore them.

Something like an extra_args keyword argument that accepts a list so we can expand the flags to SSH would be ideal.

ceph-deploy issue opened to track this: http://tracker.ceph.com/issues/6104

@axw
Copy link
Member

axw commented Aug 25, 2013

I don't mind adding extra_args, but I think there should be an option specifically for allocating a pseudo-TTY. As well as OpenSSH, there's also PuTTY/plink (in this case it has the same format) and paramiko clients to consider.

@alfredodeza
Copy link
Contributor Author

If I know that I am using native (as opposed to PuTTY) then the only thing I need is to be able to pass in extra flags to extend the arguments for SSH. If the native SSH client is the only one supporting it I don't see why it would be a problem.

That transport is almost there, extending the arguments with some flags, I am only asking to go one step further and allow honoring extra flags.

@axw
Copy link
Member

axw commented Aug 26, 2013

@alfredodeza I don't have a problem with having extra_args (I will do this), I'm just saying that in this case I'll probably add another option that the other two transports will accept too. I'm away for work at the moment, but I should have this change in in a few days.

@axw
Copy link
Member

axw commented Aug 29, 2013

I started having a look at this this evening. It's not as trivial as adding extra_args. Since the spawned ssh process is not connected to a terminal, ssh ignores "-t". It would need a pty itself.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants