ssh: connect to host github.com port 22: Connection refused
Solution 1:
Have you tried using port 443, and adding ssh.
subdomain prefix?
This command will test it. You should get an error since a shell is not supported.
ssh -T -p 443 [email protected]
Then you can use a full URL to specify the project path, see Stack Overflow answer for details:
ssh://[email protected]:443/yourname/reponame.git
Solution 2:
If you get a connection refused, it means you actually got a packet back which states that your destination does not accept your connection. This could mean a few things:
github.com is down (not too likely, but you could always check their status on https://status.github.com/)
you have an invalid IP address for github.com (manual entry in /etc/hosts or your resolver) which blocks ssh from at least your IP address
you have a firewall along the way to github.com which blocks the ssh traffic (eg. local firewall or corporate firewall)