gitolite允许已经在authorized_keys文件中存在的用户

我使用gitolite来限制一个存储库的权限,它迄今为止工作得很好,直到我试图克隆和推送用户的公钥已经在authorised_keys中添加,而不是通过gitolite。 我认为问题是我正在使用有权访问服务器的密钥。 当我尝试克隆服务器:reponame,我得到一个错误说,存储库不存在,当我从存储库/ reponame克隆,并尝试推,我得到以下错误:

Counting objects: 3, done. Delta compression using up to 4 threads. Compressing objects: 100% (3/3), done. Writing objects: 100% (3/3), 370 bytes | 0 bytes/s, done. Total 3 (delta 2), reused 0 (delta 0) remote: Empty compile time value given to use lib at hooks/update line 6 remote: Use of uninitialized value in require at hooks/update line 7. remote: Can't locate Gitolite/Hooks/Update.pm in @INC (@INC contains: /Library/Perl/Updates/5.10.0 /System/Library/Perl/5.10.0/darwin-thread-multi-2level /System/Library/Perl/5.10.0 /Library/Perl/5.10.0/darwin-thread-multi-2level /Library/Perl/5.10.0 /Network/Library/Perl/5.10.0/darwin-thread-multi-2level /Network/Library/Perl/5.10.0 /Network/Library/Perl /System/Library/Perl/Extras/5.10.0/darwin-thread-multi-2level /System/Library/Perl/Extras/5.10.0 .) at hooks/update line 7. remote: BEGIN failed--compilation aborted at hooks/update line 7. remote: error: hook declined to update refs/heads/master 

有没有办法让已经有权访问服务器的用户拥有gitolite存储库的权限? 我知道我可以为用户使用另一个密钥,并将其添加到gitolite keydir,但这些用户访问gitolite存储库也更自然。

tl; dr版本:对gitolite使用单独的密钥文件。

迟到总比不到好。

只需添加已经存在的密钥文件到gitolite / keys dir,git add,git commit,git push。 gitolite会生成一条消息

 remote: WARNING: keydir/keyfile_which_was_added.pub duplicates a non-gitolite key, sshd will ignore it 

和/ /home/git/.ssh/authorized_keys持有两次的关键,一旦已经存在和另一个在

 # gitolite start 

 # gitolite end 

部分。

我试图移动# gitolite节后的现有(旧)密钥,但是我的SSHlogin只显示gitolite消息并退出。

解决scheme将使用一个单独的公钥作为gilolite