Skip to content

Instantly share code, notes, and snippets.

@rbenaley
Created July 28, 2011 16:03
Show Gist options
  • Save rbenaley/1111823 to your computer and use it in GitHub Desktop.
Save rbenaley/1111823 to your computer and use it in GitHub Desktop.
GitHub ssh access via HTTP Proxy
host github.com
user git
hostname ssh.github.com
port 443
proxycommand socat - PROXY:<hostname>:%h:%p,proxyport=<port>
@hongbosun77
Copy link

git clone git@github.com:rbenaley/erlang_samples

Cloning into 'erlang_samples'...
/bin/bash: -c: line 0: syntax error near unexpected token newline' /bin/bash: -c: line 0: exec socat - PROXY::ssh.github.com:443,proxyport='
ssh_exchange_identification: Connection closed by remote host
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

@regalstreak
Copy link

Works perfectly. Thanks.
Just put the file contents in ~/.ssh/config and not ssh_config

@liuwenyao
Copy link

Very useful, especially for developers behind Gfw.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment