Skip to content

Make local and remote ports configurable - #84958

Merged
Benjamin Pasero (bpasero) merged 6 commits into
microsoft:masterfrom
SoraKumo001:vscode-web
Nov 18, 2019
Merged

Benjamin Pasero (bpasero) merged 6 commits into
microsoft:masterfrom
SoraKumo001:vscode-web

Conversation

@SoraKumo001

Copy link
Copy Markdown
Contributor

Modification to enable handling in cases where local port and remote port are different

#RemotePort=30000 LocalPort=8080
yarn web --port=30000 --local_port=8080

@bpasero

Copy link
Copy Markdown
Contributor

What is the scenario to support here?

@bpasero Benjamin Pasero (bpasero) added the info-needed Issue requires more information from poster label Nov 18, 2019
@SoraKumo001

Copy link
Copy Markdown
Contributor Author

When vscode-web was tested on vscode-online, there was a difference between the local port number and the remote address port to check from the browser during execution.
At this time, the script address output from vscode-web to the browser indicates the local port, causing a problem in operation.
This content is to deal with it.

@bpasero

Copy link
Copy Markdown
Contributor

Could this be documented somehow in the args?

@bpasero

Copy link
Copy Markdown
Contributor

Something like showing help output when running "yarn web --help"

@msftclas

Microsoft Contribution License Agreements (msftclas) commented Nov 18, 2019 •

Copy link
Copy Markdown

CLA assistant check
All CLA requirements met.

@bpasero Benjamin Pasero (bpasero) left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for doing this, some feedback provided.

Comment thread scripts/code-web.js Outdated
server.listen(PORT, () => {
console.log(`Web UI available at ${SCHEME}://${AUTHORITY}`);
server.listen(LOCAL_PORT, () => {
console.log(`Operating location at http://0.0.0.0:${LOCAL_PORT}`);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would only print this if the local port is different from the remote? Otherwise a bit confusing

Comment thread scripts/code-web.js Outdated
if(args.help){
console.log(
'yarn web [options]\n' +
' --no-launch Launch browser\n' +

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the text is wrong, if specified this does not launch the browser, right?

Comment thread scripts/code-web.js Outdated
console.log(
'yarn web [options]\n' +
' --no-launch Launch browser\n' +
' --scheme Potocol\n' +

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe Protocol (https or http)

@bpasero Benjamin Pasero (bpasero) added web Issues related to running VSCode in the web and removed info-needed Issue requires more information from poster labels Nov 18, 2019
Changed to show additional message only when local port is changed.
@bpasero
Benjamin Pasero (bpasero) merged commit 7021e20 into microsoft:master Nov 18, 2019
@bpasero

Copy link
Copy Markdown
Contributor

Thanks!

@github-actions github-actions Bot locked and limited conversation to collaborators Mar 27, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

web Issues related to running VSCode in the web

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants