Gitosis not updating server configuration after push of configuration changes
Asked Answered
B

5

4

I've set up gitosis using the tutorial privided at:

http://scie.nti.st/2007/11/14/hosting-git-repositories-the-easy-and-secure-way

I found that I was unable to push and create a new repository after adding the appropriate permissions in the gitosis.conf. I would continually get "read access Denied" error. I ended up checking the actual repository on the server which contained my updated gitosis.conf file. However when I checked the '.gitosis.conf' file located in the home folder of the gitosis user, I found that it was not updated. Once I replaced the contents of this file with the one in the repository I was able to create and use the new repository with no problems.

Does anyone know what could be causing this? I know that gitosis uses a post-update hook to update the server appropriately, so I think the problem most likely resides around that.

Thanks in advance! Bryan

Bobwhite answered 24/9, 2009 at 22:27 Comment(0)
D
9

Check the permissions on the post-update hook in the repository. It must be executable, and the published version of gitosis doesn't ensure that.

Dimidiate answered 24/9, 2009 at 23:59 Comment(3)
Me too, and was not able to find out the solution.Bandanna
My post-update hook was actually pointing to a nonexistent version of the python egg (was pointing to 2.6 on a 2.7 install). This answer gave me the tipoff, thanks. (And the permissions were wrong also).Misbelief
@RandyFay: You really shouldn't be setting up a Gitosis install these days - it's complete abandonware. Gitolite has completely surpassed it, and is well supported.Dimidiate
U
3

I found this problem on Ubuntu 9.04. When I looked into it, I found that the post-update hook pointed to /usr/share/python-support/gitosis/gitosis-0.2-py2.5.egg/gitosis/templates/admin/hooks/post-update which no longer existed. I'm sure it came through some updated package.

I looked around on the filesystem and found that if I pointed hooks/post-update to /usr/share/python-support/gitosis/gitosis/templates/admin/hooks/post-update it worked just fine.

Utas answered 3/11, 2009 at 17:45 Comment(1)
I get a similar error, but a /usr/share/python-support/gitosis directory doesn't even exist for me.Limbate
D
2

when I checked the '.gitosis.conf' file located in the home folder of the gitosis user, I found that it was not updated.

That's really weird -- on my gitosis installation, the .gitosis.conf in the "gitosis" user's home directory is a symlink. You might want to check that; perhaps gitosis thinks the repository is somewhere other than where you think it is?

Also, adding a section to your conf file like this:

[gitosis]
loglevel = DEBUG

can help you figure out a lot of problems with gitosis.

Decentralization answered 24/9, 2009 at 23:32 Comment(2)
what does setting the log level actually do? I've tried this and I'm getting the exact same output.Sweaty
@Sweaty Usually it provides a bunch of information about what it thinks it's trying to do. The fact that you're not seeing any difference suggests you have a deeper problem. You might try asking a more detailed question here.Decentralization
G
0

I tried to cover with commons error for Gitosis installation and setup

http://jerabi.com/sdionne/blog/2010/09/06/git-repository-server-gitosis-on-win7-troubleshooting/

I hope that can help you

Gabfest answered 11/9, 2010 at 23:39 Comment(0)
M
0

I know this is short but you probably just need to make the post hook executable...

sudo chmod 755 [your-path-to-your-repo]/gitosis-admin/hooks/post-update

Meaningless answered 11/7, 2013 at 21:3 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.