Question

I configured gitolite according to README from github.com/sitaramc/gitolite. The user in gitolite server is git. I changed the gitolite.conf under /home/john/gitolite-admin/conf in the workstation, where I added a foo repo. After that, I git push and I checked the server. The /home/git/repositories in the server got the new foo repo. The repo foo is RW+. In that case, I assumed that the gitolite works ok. So, I:

git add test.txt
git commit -m "add test file"
git remote rm origin
git remote add origin git@192.168.1.5:/home/git/repositories/foo.git
git push origin master

But I got the error message:

FATAL: W any home/git/repositories/foo John DENIED by fallthru 
(or you mis-spelled the reponame)
fatal: The remote end hung up unexpectedly.

I have no clue about this error. Can someone give any suggestions? Thanks in advance.

Was it helpful?

Solution

You don't see "git@xxx:/home/git/repositories/foo.git" urls in the README.

What you see is:

git@xxx:foo

In other word, you must not specify the full path.

Plus, make sure you don't delete origin in your local repo gitolite-admin.

If you have a new repo foo, you must clone it somewhere else:

git clone git@xxx:foo

I suspect you have only one ssh public/private key, but if you have to maintain several identities, see "Multiple gitolite users on one machine".

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top