Skip to content

Instantly share code, notes, and snippets.

@RyanNutt
Last active December 3, 2019 16:26
Show Gist options
  • Save RyanNutt/435ee100b1060bef975d40929f5b3066 to your computer and use it in GitHub Desktop.
Save RyanNutt/435ee100b1060bef975d40929f5b3066 to your computer and use it in GitHub Desktop.
Needed to git push over an SSH tunnel

Going to leave this here for next time I need to push or pull to a git repo that's blocked on a network. In my case it was a self hosted Gitlab server.

I've got an SSH tunnel setup through PuTTY running on port 1234. Run this before pushing.

git config http.proxy 'socks5://127.0.0.1:1234'

And then this after to turn it back off.

git config --unset git.proxy
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment