Skip to content

Connecting to JupyterHub from VS Code

Don Jayamanne edited this page Sep 19, 2023 · 8 revisions

The Existing JupyterHub Server... category lists remote JupyterHub servers previously connected. You can also use this option to connect to an existing JupyterHub server, for example http://<ip-address>:<port>/ and past it in the Enter the URL of the running JupyterHub Server... option to connect to the remote JupyterHub server and executed code against your notebook using that server.

Note: You will need your username and password/API token to authenticate against the JuptyerHub server.

When staring JupyterHub servers, be sure to:

  1. Allow all origins (i.e. ensure the setting c.Spawner.args = ['--NotebookApp.allow_origin=*'] is initialized in the JupyterHub config)
    This allows the server to be accessed extrenally.

Once connected, all active Jupyter sessions will appear on this list.

You can create a new session from the server's kernelspec by:

  1. Running the Notebook: Select Notebook Kernel command
  2. Choose Select Another Kernel
  3. Choose Existing JupyterHub Server...
  4. Select your server
jupyterHubPreview.mp4
Clone this wiki locally