Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Connect from a remote host? #398

Closed
blablablerg opened this issue Sep 9, 2020 · 7 comments
Closed

Connect from a remote host? #398

blablablerg opened this issue Sep 9, 2020 · 7 comments

Comments

@blablablerg
Copy link

Hello,

I am new to Julia, and I don't know how to find package documentation (yet), so I might ask a stupid question.

So I am trying to do the new julia course, but I run julia on a remote host (on the LAN). When I start Pluto.jl with Pluto.run(), I can connect to the server on the host itself but not over the network.

When I check netstat, I see that the server is listening on 127.0.0.1:1234. I think that I want this to be 0.0.0.0:1234, so that I can connect from a remote host.

Any of you know how to do that? Much appreciated. The host I want to use runs Debian.

@fonsp
Copy link
Owner

fonsp commented Sep 9, 2020

Hi! You can do:

Pluto.run("0.0.0.0", 1234)

let me know if this works!

@blablablerg
Copy link
Author

It does! Thank you.

@fonsp fonsp closed this as completed Sep 9, 2020
@fonsp
Copy link
Owner

fonsp commented Sep 9, 2020

(This syntax will change very soon - sorry in advance :)))))

@erny123
Copy link

erny123 commented Aug 19, 2023

Anyone have an update on this?

I'm SSH'ing to my computer's HPC and the regular way of getting a jupyter notebook is:

jupyter notebook --no-browser --ip=$(hostname -s) --port=8989

The hostname being something like the compute node: hpc3-22-04

And then in putty I would set it as done here

With
sourceport: 8989
Destination: hpc3-22-04:8989

Any advice?

@ctrekker
Copy link
Collaborator

If you want a one-liner that works from the terminal, this should do it.

julia -e "using Pluto; Pluto.run(host=\"0.0.0.0\", port=1234, launch_browser=false)"

Then you can open Pluto by going to hpc3-22-04:1234/?secret=<paste secret here>

@erny123
Copy link

erny123 commented Sep 9, 2023

@ctrekker Ok looks like rather than pasting the:
https://hpc3-22-04:1234/?secret=<paste secret here>
or
https://0.0.0.0:1234/?secret=<paste secret here>

I had to use:
https://127.0.0.1:1234/?secret=<paste secret here>
and it worked!

It's interesting that even when I specifically used that ip address:
Pluto.run(host="127.0.0.1", port=1234, launch_browser=false)

It didn't work.

@ctrekker
Copy link
Collaborator

ctrekker commented Sep 9, 2023

Glad you found a solution! I'm guessing there's something on your computer acting as a proxy, since 127.0.0.1 would normally loopback to a server running locally. VSCode acts as a proxy in this manner if connected via SSH to the remote - maybe PuTTY does something similar.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants