ob-ipython icon indicating copy to clipboard operation
ob-ipython copied to clipboard

implement remote kernel support through SSH

Open smartass101 opened this issue 10 years ago • 2 comments

This uses the --ssh option of the ipython console app to create the necessary tunnels and create a new connection file with "-ssh" added (because it may use different ports). Therefore, the REPL is created before the driver.

The connection file naming convention of "emacs-*.ssh" is abandoned in order to support arbitrary remote kernel connection files including "-" characters (e.g. "kernel-36465-ssh.json"), so all non-whitespace characters are matched by ExecuteHandler.

Since setting up SSH tunnels can take a while and only after that will the modified connection file be available to the driver another sleep must be used if SSH is invoked. The sleep delay is made customizable and documented.

Fixes #11

smartass101 avatar Dec 06 '15 15:12 smartass101

Warning: At the time of writing this jupyter_cleint is broken (https://github.com/jupyter/jupyter_client/issues/102) and the --ssh option does not save the new configuration file. I submitted a PR with a fix (https://github.com/jupyter/jupyter_client/pull/103), not sure when they'll merge it. For the time being it has to be tested with the applied fix I proposed.

smartass101 avatar Dec 06 '15 20:12 smartass101

Is this still relevant now that I've merged #71 ?

gregsexton avatar Jun 28 '17 13:06 gregsexton