1

I have a redmine server and a gitolite server on the same machine. I want Redmine's GIT repository to get updated when a commit is registered. I thought of adding a post-receive script that updates the repository:

post-receive:

cd home/redmine/repositories/repo
git pull

this doesn't work because the script is run by the gitolite user instead of the redmine user owner of the repository cloned folder. How can I change the user that executes the script inside a batch script?, is there a cleaner way of updating the repository?

thanks in advance.

1
  • don't have enough rank to add the gitolite tag which could be suitable for this question.
    – eliocs
    Dec 31, 2010 at 0:20

1 Answer 1

0

In the end I used a cron task to update the repository every 5 minutes. details can be found here: http://www.redmine.org/wiki/1/HowTo_keep_in_sync_your_git_repository_for_redmine.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .