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

https://github.com/vitejs/vite/issues/1989 also applicable to using vs-code over ssh. #6345

Closed
7 tasks done
gmos opened this issue Dec 31, 2021 · 2 comments
Closed
7 tasks done

Comments

@gmos
Copy link

gmos commented Dec 31, 2021

Describe the bug

When you use vs-code for editing/debuging over ssh against the VSCode server and Vite running on another host, or in WSL or in a Docker container, the the remote VSCode server will proxy the Vite port to the VSCode host, remapping the port number. As described earlier in #1989 by @FractalHQ this will reload the page/app every second or so.

While in my case Vite runs remotely on localhost:4000 it runs locally on localhost:. The client tries to contact the original ws://localhost:4000, which clearly doesn't work.

Would it be possible to make it use the remapped port number from the url for the ws call-back?

Reproduction

Connect from one host to another using the ssh explorer and run vite in development mode.

System Info

Using vite v2.7.6  and VSCode 1.63.2.

Used Package Manager

pnpm

Logs

No response

Validations

@gmos
Copy link
Author

gmos commented Dec 31, 2021

Tried to log this extra use-case to the original #1989, but it was locked by a bot.

@sapphi-red
Copy link
Member

Closing as #8650 fixed this.
I tested with ssh port fowarding.

@github-actions github-actions bot locked and limited conversation to collaborators Jul 23, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants