Skip to content

Instantly share code, notes, and snippets.

@GoodNovember
Created February 21, 2019 15:44
Show Gist options
  • Select an option

  • Save GoodNovember/0149060828dc22809617c154ca6312bb to your computer and use it in GitHub Desktop.

Select an option

Save GoodNovember/0149060828dc22809617c154ca6312bb to your computer and use it in GitHub Desktop.
Git Fixes

Problem: Git shows:

$ git clone git@ssh.github.com:443/junk-code/spine.git
Cloning into 'spine'...
ssh: Could not resolve hostname ssh.github.com: Name or service not known
fatal: Could not read from remote repository.

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

And you have all the rights you want/need.

The host you are on might be blocking SSH connections to github.

The fix is as follows:

Solution:

first, test to see if when you run this command: ssh -T -p 443 git@ssh.github.com you this back:

Hi ${github-username}! You've successfully authenticated, but GitHub does not provide shell access.

If not: See This

Create a file in ~/.ssh/ called config if it does not exist and add the following to it:

Host github.com
  Hostname ssh.github.com
  Port 443

This allows us to use SSH over a HTTPS port instead of the usual SSH port.

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