【发布时间】:2017-06-29 17:22:03
【问题描述】:
所以我实际上对 git 非常熟悉。但是我从来没有设置过我自己的 git server。因此,以下内容应该是不言自明的。
无论如何:我想在我的 Windows 客户端上检查我的 get repo per ssh。但是我收到一个错误,说 repo 不存在或者我有足够的权限。实际上我对 repo 有权限并且 repo 确实存在。我不确定我的问题出在哪里。我可以从我的客户端 ssh 进入服务器。
服务器(Linux)
$ whoami
foo
$ mkdir /git/myrepo && cd /git/myrepo
$ git --bare init
客户端(带有cmder/conemu的windows)
# user foo is in group git
$ git clone ssh://foo@myserver/git/myrepo myclone
Cloning into 'myclone'...
foo@myserver's password:
fatal: '/git/myrepo' does not appear to be a git repository
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
我也尝试过 git 协议 - 但由于我对这个协议不是很熟悉,所以我只是切换到 ssh
$ git clone git://myserver/git/myrepo myclone
Cloning into 'myclone'...
fatal: unable to connect to myserver:
myserver[0: 192.168.178.50]: errno=No error
【问题讨论】: