Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
42 changes: 21 additions & 21 deletions advanced_topics/connect_vscode_to_geolab.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ special "proxy" extension is needed.
On your laptop:

- **VS Code**
- **Jupyter extension** (`ms-toolsai.jupyter`)
- **Python extension** (`ms-python.python`) — installed automatically as a dependency of the Jupyter extension
- **JupyterHub extension** (`JupyterHub`)

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

clarify these are vscode extensions, not separate apps

- **Python extension** (`ms-python.python`)

In GeoLab:

Expand Down Expand Up @@ -80,43 +80,43 @@ Copy that entire line — you will paste it into VS Code in the next section.

## VS Code side: connect to the server

1. Install the **Jupyter** extension (`ms-toolsai.jupyter`) from the Extensions
1. Install the **Jupyter** extension (`JupyterHub`) from the Extensions
view if you have not already.

![Installing ms-toolsai](../img/add_ms-toolsai_extension.png)
![Installing ms-toolsai](../img/jupyterhub.png)

2. Open or create a notebook file (`.ipynb`) in VS Code.

3. Click the **kernel picker** in the top-right of the notebook (it may read
"Select Kernel").
3. Click the **kernel picker** in the top-right of the notebook ("Select Kernel").

![Select Kernel](../img/select_kernel_vscode.png)
![Select kernel](../img/select_kernel_vscode.png)

4. Choose **Select Another Kernel...**
4. Choose **Enter the URL of the running JupyterHub Server...**

![Select anther kernel](../img/select_another_kernel.png)
![Select anther kernel](../img/select_a_jupyter_server.png)

5. Choose **Existing Jupyter Server...**
5. Choose **Enter the URL of running JupyterHub server**. Paste the full tokenized URL you copied from GeoLab, including the
`?token=...` part, then press Enter.

![Exisiting Jupyter Server](../img/existing_jupyter_server.png)
![Exisiting Jupyter Server](../img/enter_jupyterhub_url.png)

6. Choose **Enter the URL of a running Jupyter server**.
7. Press `Enter` for **Enter your username..**

![Enter URL](../img/enter_url_jupyter_server.png)
![Enter username (press Enter)](../img/jupyterhub_enter_username.png)

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's kinda self-explanatory from the screenshot, but a little extra text on finding your Auth0 id and "this is not the email address you used to log in" might be helpful if images fail to resolve, or for agents parsing our docs


7. Paste the full tokenized URL you copied from GeoLab, including the
`?token=...` part, then press Enter.
8. Press `Enter` for **Enter your password or API token...**.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Again, add more detail that this is the 'token' part of the URL and not the password you used to log in to geolab. Or have the code snippet above print the token separately from the built URL?


![Accept display name](../img/jupyterhub_enter_password.png)

8. When prompted, accept or edit the display name for the server.
9. Optional: **Change server name**

![Accept display name](../img/jupyter_server_display_name.png)
![Change server name (optional)](../img/jupyterhub_change_server_name.png)

9. Back in the kernel picker, select the kernel exposed by the remote server
(for example, the Python 3 kernel from your GeoLab environment).
10. **Select a Kernel from JupyterHub GeoLab**. Choose `Python 3 (ipykernel)` to select a new kernel.

![Select kernel](../img/select_jupyter_kernel.png)
![Select kernel](../img/jupyterhub_select_kernel.png)

10. Run a cell to confirm. Execution now happens inside your GeoLab pod, using
11. Run a cell to confirm. Execution now happens inside your GeoLab pod, using
the GeoLab environment and compute — not your laptop.

---
Expand Down
Binary file added img/enter_jupyterhub_url.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed img/enter_url_jupyter_server.png
Binary file not shown.
Binary file removed img/jupyter_server_display_name.png
Binary file not shown.
Binary file added img/jupyterhub.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added img/jupyterhub_change_server_name.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added img/jupyterhub_enter_password.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added img/jupyterhub_enter_username.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added img/jupyterhub_select_kernel.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added img/select_a_jupyter_server.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed img/select_another_kernel.png
Binary file not shown.
Binary file removed img/select_jupyter_kernel.png
Binary file not shown.
Binary file added img/select_jupyterhub.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.