git protocol connection refused


I created a GIT Remote Repository in localhost.
Then I push my project.
I can clone my project via :

git clone ssh://

But when I want to use git:// or http:// I get the following error:

$ git clone git://
Cloning into 'haq'...
fatal: unable to connect to[0:]: errno=Connection refused

How do I solve it?


You’re not running a http server, so you cannot use http to access your repo. It’s as simple as that.

Same for the (mostly obsolete) git protocol.

When setting up a http server for git access, you typically have bare repos where you push to from your working non-bare repos. You would not use the same repo.

Answered By – Marcus Müller

This Answer collected from stackoverflow, is licensed under cc by-sa 2.5 , cc by-sa 3.0 and cc by-sa 4.0

Leave a Reply

(*) Required, Your email will not be published