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

Allow customizing vscode-server ports #3706

Closed
marius311 opened this issue Sep 21, 2020 · 2 comments
Closed

Allow customizing vscode-server ports #3706

marius311 opened this issue Sep 21, 2020 · 2 comments
Labels
ssh Issue in vscode-remote SSH

Comments

@marius311
Copy link

This is a feature request / question. I'm using a remote cluster where port forwarding is disabled administratively by a firewall, however, I can reverse tunnel fine. By this I mean,

mylaptop$ ssh -L 1234:localhost:1234 cluster # blocked by firewall
cluster$ ssh -R 1234:localhost:1234 mylaptop # works correctly

Using remote-ssh, if I try to connect to this cluster, the initial SSH connection to spawn the server runs fine, but the secondary connection to set up the port forwarding fails, as expected given the above firewall. However, if I could just reverse forward the ports by hand, then I believe it could work. What I need are to figure out what ports are chosen, or set them by hand.

I've figured out that remote-ssh launches the server with --port 0, and I can figure out which emphemral port was chosen by looking in ~/.vscode-server/*.log, which prints the port. However, I can't figure out what port was chosen on the local side.

A question I have is whether there exists a way I can figure out the local port? If not, my feature request is that 1) there be some way I could figure it out or 2) even better, I could just specify fixed local and remote ports by hand.

Would be very happy if there are other suggestions for how to deal with this setup. Thanks.

Some info: vscode 1.49.0, remote-ssh 0.55.0, remote OS Scientific Linux release 7.4, local OS Ubuntu 20.04.

@github-actions github-actions bot added the ssh Issue in vscode-remote SSH label Sep 22, 2020
@gyzerok
Copy link

gyzerok commented Oct 23, 2020

This issue looks like a duplicate for #1386.

I would suggest to close this one and upvote the one I mentioned. Hopefully more upvotes will result in sooner fix than more issues.

@marius311
Copy link
Author

Yep, I think its a dup, thanks. Will close and comment there.

@github-actions github-actions bot locked and limited conversation to collaborators Dec 7, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
ssh Issue in vscode-remote SSH
Projects
None yet
Development

No branches or pull requests

2 participants