code-server icon indicating copy to clipboard operation
code-server copied to clipboard

[Docs]: Why is it possible to connect to code-server with SSH if I use cloudflare tunnel and ngrok?

Open Moius opened this issue 2 years ago • 9 comments

cloudflare tunnel and ngork just provide a springboard server about ssh, what is the difference between this and using SSH to connect to code-server directly? And there is a part of the documentation inaccurate description, in the section using cloudflare tunnel. "Run cloudflared tunnel --url ssh://localhost:22 on the remote server" Here there is no hint in the remote server also to install cloudflared. At the same time the above ~/.ssh/config document in the user settings also does not match the user name used in the following connection.

Moius avatar Oct 02 '22 15:10 Moius

cloudflare tunnel and ngork just provide a springboard server about ssh, what is the difference between this and using SSH to connect to code-server directly?

Good question...I'm not as familiar with cloudeflare tunnel but i've used ngrok in the past when I want to expose my code-server and access from a separate machine. I guess those tools provide SSL out of the box? cc @code-asher

And there is a part of the documentation inaccurate description, in the section using cloudflare tunnel. "Run cloudflared tunnel --url ssh://localhost:22 on the remote server" Here there is no hint in the remote server also to install cloudflared. At the same time the above ~/.ssh/config document in the user settings also does not match the user name used in the following connection.

Please open a PR to update it!

jsjoeio avatar Oct 04 '22 16:10 jsjoeio

cloudflare tunnel and ngork just provide a springboard server about ssh, what is the difference between this and using SSH to connect to code-server directly?

Good question...I'm not as familiar with cloudeflare tunnel but i've used ngrok in the past when I want to expose my code-server and access from a separate machine. I guess those tools provide SSL out of the box? cc @code-asher

And there is a part of the documentation inaccurate description, in the section using cloudflare tunnel. "Run cloudflared tunnel --url ssh://localhost:22 on the remote server" Here there is no hint in the remote server also to install cloudflared. At the same time the above ~/.ssh/config document in the user settings also does not match the user name used in the following connection.

Please open a PR to update it!

I only used the cloudflared tunnel to connect, and the result was that the VS code Remote SSH expansion did not use any files from the code-server. Instead, a new .vscodeserver file was created.

Moius avatar Oct 04 '22 16:10 Moius

I only used the cloudflared tunnel to connect, and the result was that the VS code Remote SSH expansion did not use any files from the code-server. Instead, a new .vscodeserver file was created.

Interesting...AFAIK, you can't use VS Code Remote SSH with code-server so I wouldn't expect that to work unfortunately.

jsjoeio avatar Oct 04 '22 16:10 jsjoeio

I only used the cloudflared tunnel to connect, and the result was that the VS code Remote SSH expansion did not use any files from the code-server. Instead, a new .vscodeserver file was created.

Interesting...AFAIK, you can't use VS Code Remote SSH with code-server so I wouldn't expect that to work unfortunately.

The problem here is that the documentation describes "SSH into code-server on VS Code", but actually using SSH connection on VScode using the method in the article has nothing much to do with code-server, not SSH to code-server. I think this description is not accurate.

Moius avatar Oct 04 '22 16:10 Moius

Maybe the document needs another revision 😂

Moius avatar Oct 04 '22 16:10 Moius

Lol probably so...feel free to add more changes!

jsjoeio avatar Oct 04 '22 18:10 jsjoeio

Yeah that documentation is confusing to me as well. It seems like we should just remove that section entirely because it is about VS Code remote and nothing to do with code-server as noted.

code-asher avatar Oct 04 '22 18:10 code-asher

This is really need to be removed. Confused me as well. It's just explaining how to SSH to machine and not related to code-server at all.

YanivYoobic avatar Mar 12 '23 08:03 YanivYoobic

Yes, this section is super confusing, definitely seemed to imply that the SSH connection could be used by e.g. VSCode Remote SSH, to connect to the existing code-server instance on the remote machine.

tmchartrand avatar Aug 09 '23 21:08 tmchartrand