当我尝试克隆git用户的外部远程git时,我得到了一个错误。
Cloning into test...
fatal: '/media/raid/repo/test.git' does not appear to be a git repository
fatal: The remote end hung up unexpectedly我不确定为什么会出现这个错误,我想要做的是将git移到另一个磁盘上。目前,git驻留在我的git用户家中,当它驻留在用户空间时,我可以毫不费力地从该git进行克隆。我尝试过通过软链接和直接通过挂载路径访问另一个磁盘,但没有成功。
在git服务器上运行Ubuntu 12.04,git用户可以访问ssh。
这里是一些基本的测试,在我的raid磁盘上,我有一个副本,如果test.git。
/home/git [git user's home]
lrwxrwxrwx 1 git git 11 Jan 8 21:22 tst.git -> test.git//
drwxr-xr-x 7 git git 4096 Jan 8 21:20 test.git/
lrwxrwxrwx 1 git git 18 Jan 7 06:48 repo -> /media/raid/repo//
/media/raid/repo [The preferred location]
drwxrwxr-x 7 git git 4096 Jan 4 10:33 test.git/
OK - git clone gitserver:/home/git/test.git
OK - git clone gitserver:/home/git/tst.git
NOK - git clone gitserver:/home/git/repo/test.git
NOK - git clone gitserver:/media/raid/repo/test.git这是我遗漏的一些基本的Linux安全性,还是一个git问题?
发布于 2013-01-10 04:44:37
找到原因..。Git用户没有访问/media/raid的权限,这是我的一个小错误。因此,现在我可以软链接到raid,并且能够使用以下语法访问:
git clone gitserver:repo/test.git尽管如此,我还是觉得这个错误消息相当奇怪。
发布于 2013-01-09 05:28:43
看起来你的道路是不完整的。您的路径应该类似于:/HOME/USER/media/raid/repo/test.git
https://stackoverflow.com/questions/14224248
复制相似问题