permission denied...
Monday, 18. February 2008, 15:13:26
For several hours I tried to fix a small "bug" in my subversion installation, but without any results. I commited a file to subversion successfully, but the hook "post-commit" didn't do anything at all. So I logged on to my server, started the hook manually and it worked perfectly.
So what went wrong? Well... it all started with my login to the server. As I'm pretty lazy, I (locally) logged in as root, installed subversion, created the logfiles and so on. Everything seemed fine and as commiting worked too I was pretty happy. Then I changed the hook to update the logfiles but nothing happened. I started the hook manually... and it worked.
So I started to read several blogs about subversion, read online manuals, tutorials and so on... nothing helped.
When I asked a friend concerning this problem I suddenly had an idea... I logged on the server switched the user to my testuser and started the hook manually:
After adjusting the permissions and ownership of the logfile everything works totally fine now. I still can't believe how blind I have been...
So what went wrong? Well... it all started with my login to the server. As I'm pretty lazy, I (locally) logged in as root, installed subversion, created the logfiles and so on. Everything seemed fine and as commiting worked too I was pretty happy. Then I changed the hook to update the logfiles but nothing happened. I started the hook manually... and it worked.
So I started to read several blogs about subversion, read online manuals, tutorials and so on... nothing helped.
When I asked a friend concerning this problem I suddenly had an idea... I logged on the server switched the user to my testuser and started the hook manually:
[testuser@localhost hooks] $ sh post-commit post-commit: line 54: /var/log/svn/project.log: Permission denied post-commit: line 55: /var/log/svn/project.log: Permission denied
After adjusting the permissions and ownership of the logfile everything works totally fine now. I still can't believe how blind I have been...