-
Notifications
You must be signed in to change notification settings - Fork 8
Connecting to JupyterHub from VS Code
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 paste 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 add the following configuration settings into the JupyterHub config file:
origin = '*'
c.Spawner.args = [f'--NotebookApp.allow_origin={origin}']
c.JupyterHub.tornado_settings = {
'headers': {
'Access-Control-Allow-Origin': origin,
'Access-Control-Allow-Private-Network': 'true',
},
}
For more information on this check the following links:
Once connected, all Jupyter KernelSpecs and active Jupyter sessions will appear on this list.
You can start a new Jupyter session from the server's kernelspec by:
- Running the
Notebook: Select Notebook Kernel
command - Choose
Select Another Kernel
- Choose
Existing JupyterHub Server...
- Select your server