git/github how to use a nonstandard port for ssh access

Here’s how:
in your ~/.ssh/config:
Host githubcorkscrew
  Port 443
  Hostname ssh.github.com
  User github_username_here
  PreferredAuthentications publickey

Then clone it

$ git clone git@githubcorkscrew:rdp/universal-scene-skipper.git

or update your .git/config to have that url instead of another.

Voila.  You are using a non standard port (443 instead of 9418), which for me works splendidly despite an external proxy and firewall that disallow ssl, and better than git over HTTPS, which seems to have been flakey lately.

Another way is to use port forwarding to some external host:

http://betterlogic.com/roger/?p=1022

Some refs: http://support.github.com/discussions/repos/2765-sshgithubcom-doesnt-seem-to-work

http://blog.codeslower.com/2008/8/Using-PuTTY-and-SSL-to-securely-access-GitHub-repositories-via-SSH

Leave a Reply

Your email address will not be published. Required fields are marked *


seven − = 6

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>