12

I tried to push some changes to GitHub using git push origin master, but after some time it showed an error:

fatal: unable to access 'https://github.com/the-unbelievable/MiniGames.git/': Failed to connect to github.com port 443: Operation timed out

I've just created that repository and have already committed twice. I'm connected to the Internet through home Wi-Fi and the OS is Mac OS X v10.10.2 (Yosemite).

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
  • 1
    Github, at the time of this question, is going through a DDOS. – blockhead Mar 29 '15 at 18:47
  • 1
    I doubt very much that you really get that error message with that url... – arkascha Mar 29 '15 at 18:50
  • @arkascha, I just copied that from terminal –  Mar 29 '15 at 18:59
  • OK, interesting. So it is not the frontend https server on their side but the internal ssh connection that fails. I would not have expected such an error is routed to the client by them... Sorry! – arkascha Mar 29 '15 at 19:03
  • If not DDoS, possibly *[Getting Git to work with a proxy server - fails with "Request timed out"](https://stackoverflow.com/questions/783811/)* – Peter Mortensen Feb 24 '23 at 05:50

4 Answers4

17

If you are behind a proxy, check the content of C:\Users\[your username]\.gitconfig and make sure a proxy is configured:

[http]
    proxy = http://yourproxy.com:8080  // Change your settings here
[https]
    proxy = http://yourproxy.com:8080  // Change your settings here
Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
Dunken
  • 8,481
  • 7
  • 54
  • 87
5

The reason is continuous DDoS attack ... https://status.github.com/messages

Striker007
  • 66
  • 2
5

From here: GitHub - failed to connect to github 443 windows/ Failed to connect to gitHub - No Error

git config --global http.proxy http[s]://userName:password@proxyaddress:port

Where port might be 3128 and userName:password might be your windows login credentials

profimedica
  • 2,716
  • 31
  • 41
  • In my case repo url is csd.com/Demo/_git/Demo and getting message Failed to connect to csd.com port 443: Timed out .. more over my pwd as @ in it.. can you please tell me what will be http[s]://userName:password@proxyaddress:port in my case... – Ziggler Nov 16 '18 at 00:08
  • Do you have username and passwrd for it? Then add them to your git config. Also, make sure you can ping the host and try to connect from another client. Your problem might not be related to this if you are not trying to connect to GitHub – profimedica Nov 17 '18 at 23:25
  • Our entire team is having issues. This happens with VS 2017 only. VS 2015 is good. We are new azure devops. This happens with VS 2017 using Azure DevOps with Team Explorer – Ziggler Nov 20 '18 at 23:39
  • Have you tried to export settings from VS 2015 and inspect them? Can you try from different networks that does not require proxi? Lan and WiFi? Are you pointing to the same resources and same protocol? Same Azure subscription and same login (work/personal) and role? I assume is a permissions issue. – profimedica Nov 21 '18 at 02:10
1

Try to configure the environment by using:

sudo vim.tiny /etc/environment

Add there:

http_proxy=http://your.proxy.server.address:port
https_proxy=http://your.proxy.server.address:port
ftp_proxy=http://your.proxy.server.address:port

Also add the proxy setup in the gitconfig file.

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131