The code works only when you have your RSA Key registered on the remote.
Goal:
Make code so works without RSA Key.
Now I couldn't find a way to get stdout. Seems like I have to use a socket.
For instance, the following gives some hint how I could use a socket:
I wrote a pretty detailed explanation of the problem at the code: https://github.com/YoungxHelsinki/automated-scripts/blob/e16a652018ce6f66045ba69f0b314c334820488d/Aalto_computer_status_checker/paniikki_jupyter_launcher.py#L12-L49
Problem
The code works only when you have your RSA Key registered on the remote.
Goal:
Make code so works without RSA Key. Now I couldn't find a way to get stdout. Seems like I have to use a socket. For instance, the following gives some hint how I could use a socket:
The above won't work if you don't have a public key set up. You get:
Check sshuttle: https://github.com/apenwarr/sshuttle/blob/083293ea0dc2ebc77f282c2803720a2bb5f21a80/sshuttle/ssh.py#L124 https://github.com/apenwarr/sshuttle/blob/083293ea0dc2ebc77f282c2803720a2bb5f21a80/sshuttle/client.py#L418
Must find a way to pass stdout like a native view. This might also enable jupyter notebook launch within Python code.