Skip to content

Instantly share code, notes, and snippets.

@incfly
Created December 16, 2021 09:05
Show Gist options
  • Save incfly/bef168bbd274cc68cb0ef1d28e34154e to your computer and use it in GitHub Desktop.
Save incfly/bef168bbd274cc68cb0ef1d28e34154e to your computer and use it in GitHub Desktop.
# Windows config.
Host <inst-name>
HostName <ip>
User fly
IdentityFile C:\Users\hujia\.ssh\google_compute_engine
# In windows, Clash proxy runs in localhost, use nmap for access. https://nmap.org/download.html
ProxyCommand C:\workspace\programs\Nmap\ncat.exe --proxy-type socks5 --proxy 127.0.0.1:7890 %h %p
# Linux config.
Host loomer-jp
HostName 34.84.98.136
User fly
IdentityFile /home/incfly/.ssh/google_compute_engine
# cat cmd finds the ip address from WSL environment.
ProxyCommand nc -X 5 -x $(cat /etc/resolv.conf | grep nameserver | cut -d ' ' -f 2|tr -d '\n'):7890 %h %p
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment