5.5.26 #26
Replies: 2 comments
-
|
Notes:
@aaarendt @egagli seems maybe some additional steps might be needed for windows WSL?... https://stackoverflow.com/questions/60150466/can-i-ssh-from-wsl-in-visual-studio-code |
Beta Was this translation helpful? Give feedback.
-
Connecting local VS Code to CryoCloud via VS Code TunnelsA guide for connecting your local VS Code Desktop to a CryoCloud JupyterHub pod This approach also works for NASA VEDA and other 2i2c-managed pangeo-style Why tunnels instead of SSH-over-websocket?The current
VS Code Tunnels sidestep all of this. The Prerequisites
Step 1: Launch a CryoCloud server and open a terminal
Step 2: Install the VS Code CLIThe mkdir -p ~/bin
cd /tmp
curl -Lk 'https://code.visualstudio.com/sha/download?build=stable&os=cli-alpine-x64' -o vscode_cli.tar.gz
tar -xzf vscode_cli.tar.gz
mv code ~/bin/
chmod +x ~/bin/code
export PATH="$HOME/bin:$PATH"
code --version
Persist the PATH change so future sessions pick it up automatically: echo 'export PATH="$HOME/bin:$PATH"' >> ~/.bashrcStep 3: Start the tunnelcode tunnel --accept-server-license-terms --name cryocloud-$(whoami)The You'll see output similar to: Open that URL in your laptop's browser, paste the code, and approve. Back in Once you see Step 4: Connect from local VS CodeOn your laptop:
First connect takes 20-60 seconds while VS Code Server installs into Step 5: Verify IRSA / S3 access worksThis is the payoff over the SSH approach. Open a terminal inside the remote env | grep -E 'AWS_ROLE_ARN|AWS_WEB_IDENTITY|AWS_REGION'Under tunnels these should be populated automatically — no aws sts get-caller-identityYou should see the assumed role ARN (something like Step 6: Keep the tunnel runningThe foreground process in step 3 dies when its terminal closes, taking the Option A:
|
SSH-over-websocket (jupyter-sshd-proxy) |
VS Code Tunnels | |
|---|---|---|
| Local prerequisites | websocat, ~/.ssh/config edits, SSH keys in ~/.ssh/authorized_keys |
Remote - Tunnels extension |
| Pod-side requirement | Image must ship jupyter-sshd-proxy |
code CLI (single binary, no system packages) |
| Authentication | JupyterHub API token + SSH public key | GitHub / Microsoft account |
| IRSA env vars in session | Not inherited; requires /proc/1/environ hack |
Inherited automatically |
| Kernel env vars | Requires ~/.ipython/profile_default/startup/00-env.py |
Inherited automatically |
| Hub support status | Experimental on VEDA | Not yet officially adopted, but works without hub-side changes |
| Inbound ports | None (tunneled over hub HTTPS) | None (outbound WebSocket to relay) |
References
- VS Code Remote - Tunnels documentation
- VEDA: How to ssh into the VEDA JupyterHub (the SSH approach)
- VEDA: How to use VS Code on the VEDA JupyterHub (browser-based
code-server) - NISAR examples — JupyterHubs notes
jupyter-sshd-proxy(Yuvi Panda)
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Attendees: Eric, Anthony, Rob, Scott
Location: eScience Seminar Room
Agenda:
Notes:
Beta Was this translation helpful? Give feedback.
All reactions