Interactive app establishing a ssh tunnel?

Hello,

My use case is that I would like to connect to a nxserver (NoMachine) running on a compute host.

My app and my cluster are already set up so that I can book a compute node and If, on my local host, I establish manually the ssh tunnel as :

ssh -L 4000:compute_host:4000 login_node

I can then proceed with the NoMachine player and successfully connect to the compute host. If important, I must say I’m using the NoMachine free version : connecting to the nxserver is only possible with the desktop nxplayer, not with the web-based player.

Do you know if there is a way that an interactive app could set up such a ssh tunnel. I believe I could use the find_port to locate a free port on my login node and I would then indicate in the view.html.erb the parameters that the user should then use in the nxplayer to connect.

I believe there is one thing I’m not completely understanding about how to combine ood with my requirement to establish this ssh tunnel.

Thank you for your help.

Jeremy

1 Like

You can enable the native connection tab with the directions below. Though I have to warn you this is broken in 4.0.0 and fixed in 4.0.1 with this patch: update from data-toggle to data-bs-toggle (#4115) by johrstrom · Pull Request #4124 · OSC/ondemand · GitHub - so it’s a bit of a mixed bag I guess.

https://osc.github.io/ood-documentation/latest/how-tos/app-development/interactive/view.html#adding-native-vnc-instructions-to-the-panel