I've been trying to find a way to make a node script automatically open up an ssh connection for me. I don't want it to run any command, just open the connection and let me start typing.
I've found this question on ways to connect: SSH client for Node.js
Every way I've found thus far has been primarily focused on opening an ssh connection and running commands with node, but I don't want any commands to be run but the ones I type myself.
The package I'm trying to use is ssh2 https://github.com/mscdex/ssh2#installation
It connects well, but I can't find an example of a way to connect process.stdio to it easily. I can imagine convoluted ways of doing it, but it seems like there must be some very simple way.
I have read the section on "interactive shell session" but it appears to be a bit of a misnomer as it really just runs ls -l then exits. No interaction there at all.
https://github.com/mscdex/ssh2#start-an-interactive-shell-session
What is the proper way to use this tool to start a normal, basic, plain ol' tty ssh session?