WSL使用主机shadowsocks代理

WSL使用主机shadowsocks代理

  • 双击小飞机,查看代理端口image-20211105190941817
  • 编辑bashrc,然后source生效
1
2
3
4
5
# proxy config
export hostip=$(cat /etc/resolv.conf |grep -oP '(?<=nameserver\ ).*')
export https_proxy="http://${hostip}:1080"
export http_proxy="http://${hostip}:1080"
export all_proxy="socks5://${hostip}:1080"
  • 测试生效

    image-20211105191349724

Your browser is out-of-date!

Update your browser to view this website correctly. Update my browser now

×