SSH bastion compatibility
See original GitHub issueHello again 😃
Pseudo-terminal
Some SSH bastion rely on ssh pseudo-terminal capabilities to work, which works on a unix terminal with this “ssh” option :
-t Force pseudo-terminal allocation. This can be used to execute arbitrary screen-based programs on a remote machine, which can be very useful, e.g. when implementing menu services. Multiple -t options force tty allocation, even if ssh has no local tty.
We’re implementing The Bastion from OVH (open-sourced recently) and it seems that we cannot make it work.
Send command on ssh connection
Also, it seems impossible to send command on ssh connection rather than the connected shell once loaded, using “launch command on connection”. OVH dev has tested and replied :
ok, the "launch command on connection" is actually waiting for a bash prompt to manually input the command you have configured (as if you typed it on your keyboard), this is different from specifying a command directly on the ssh command-line, that's why you can't make it work.
Maybe the WebSSH dev could add the feature ;)
The command line equivalent would be :
ssh -i ~/.ssh/myprivatekey -t user@bastion -- COMMAND
Example of command in case of OVH The Bastion :
root@host
That will connect to the remote server via bastion.
I know this feature request is about specific use case but I hope SSH bastion will be more frequently used (thanks to open-source project like this one), security being a critical concern in the Internet jungle 😃 And of course it’ll be a good one for pro version.
Related issue on The Bastion project : https://github.com/ovh/the-bastion/issues/54
Have a good day !
Issue Analytics
- State:
- Created 3 years ago
- Comments:13 (8 by maintainers)
Top GitHub Comments
Hello @snk33
After a lot of bad tries :
I’m now able to send commands :
Even interactive mode :
😇
I don’t think that I will implement this enhancement inside “macros” / “launch command on connection” because this enhancement is more related to the terminal settings :
So I will add this terminal settings option :
You will then be able to add any custom command, like :
I’m now working on the UI
Tested, everything’s fine now ! 😃