-
-
Save rosuH/5820995ab0838ad5fba41ce466c044b2 to your computer and use it in GitHub Desktop.
Proxy Settings for WSL2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# WSL2 | |
export hostip=$(cat /etc/resolv.conf | grep nameserver | awk '{ print $2 }') | |
alias www="https_proxy=\"http://${hostip}:8080\" http_proxy=\"http://${hostip}:8080\"" | |
# or set it global | |
export hostip=$(cat /etc/resolv.conf | grep nameserver | awk '{ print $2 }') | |
export https_proxy="http://${hostip}:8080" | |
export http_proxy="http://${hostip}:8080" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment