Skip to content

Add optional proxy support via MC_PROXY environment variable#182

Open
FruitJelliesGD wants to merge 1 commit intoGregTechCEu:mainfrom
FruitJelliesGD:feature/proxy-support
Open

Add optional proxy support via MC_PROXY environment variable#182
FruitJelliesGD wants to merge 1 commit intoGregTechCEu:mainfrom
FruitJelliesGD:feature/proxy-support

Conversation

@FruitJelliesGD
Copy link
Copy Markdown

Allows users behind network restrictions (e.g., mainland China) to route download traffic through a local HTTP/SOCKS5 proxy by setting the MC_PROXY environment variable.

Usage: in README_WINDOWS.md - Section 4

All that is left to run the server is to type

$env:MC_PROXY='http://127.0.0.1:7890'; .\start.ps1

inside of this powershell window.


When MC_PROXY is not set: behavior is completely unchanged
Server installation/update failed with exit code 1.
b6feb91a1c4c5784b255293e97adfc01


When MC_PROXY is set: all Invoke-WebRequest calls and the Java packwiz process use the specified proxy
Server installation/update complete.
d3b4bf1d0826e834ce32e6992a11e51c

Allows users behind network restrictions (e.g., mainland China) to route
download traffic through a local HTTP/SOCKS5 proxy by setting the
MC_PROXY environment variable.

Usage: $env:MC_PROXY='http://127.0.0.1:7890'; .\start.ps1

- When MC_PROXY is not set: behavior is completely unchanged
- When MC_PROXY is set: all Invoke-WebRequest calls and the Java
  packwiz process use the specified proxy
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

Successfully merging this pull request may close these issues.

1 participant