W access for gitolite-admin DENIED for user

I tried very hard to work with guitarolites. I used a batch approach and can do the first "git push" with the first user on the server. After that, if I add the key and try to press something, I get the error message “W access for gitolite-admin DENIED to mike” - note that it should use the user gitolite, and not my username. I guess this is because I am adding private keys for both users in my .bash_profile. (I am using msysgit) ...

Any ideas?

Thanks a lot!

+4
source share
2 answers

I assume this is due to the fact that I am adding private keys for both users.

True, for the gitolite user, gitolite should use a dedicated public / private key, one that is also used for ssh access.
You can confirm this by looking at the gitolite magazines (in ~gitolite/.gitolite/logs )

Multiple keys are used through the config file.
For example, as an example, " users are prompted for a password when using gitolite ."
The file %HOME%/.ssh/config may contain something like:

 HostName gitoliteserver User gitolite IdentityFile ~/.ssh/gitolite Host mikegitolite HostName gitoliteserver User mike IdentityFile ~/.ssh/id_rsa 

Do not forget to define HOME , you are on Windows: it is not defined by default)


OP Mike Gagnon confirms the following configuration in the comments :

 host gitolite user gitolite hostname myhost port 443 IdentityFile ~/.ssh/gitolite host edison user gitolite hostname myhost port 443 IdentityFile ~/.ssh/mike 
+1
source

I had a similar problem because I could only make one push to the new gitolite replica, then I lost access. I was able to fix this by adding my username to the .conf file the first time I clicked:

%> cat conf / gitolite.conf repo gitolite-admin RW + = git-admin myusername

0
source

Source: https://habr.com/ru/post/1441099/


All Articles