Content
How to setup a Git Repository for a Project?
Added by Dani Soufi over 10 years ago
Hello everyone,
I don’t seem to be able to configure my project to work with git. I run my own OpenProject server so I have the access to the configurations as well. The cloned git project directory lies inside the root folder of the OpenProject under /home/openproject/openproject/gitrepos/project-docs.git and has the same access permissions as the user. I run the whole OpenProject server under Apache2 with the help of passenger plugin.
So when I set the full path to git directory in the project’s configuration I get the error “(404) The entry or revision was not found in the repository.”. I tried to set the scm_git_command to point to the git which in my case is “/usr/bin/git”, but still no luck.
How do I set it up? Any ideas?
Best regards,
Dani
Replies (2)
Hi Dani,
I have seen this error several times when the repository was empty. Are you sure there is at least one initial commit and a master branch, just in case you’re running into this edge case issue?
Cheers,
Martin.
Hi Martin,
Thanks for the reply. It seems that I had to first of all to “git clone —bare $REPO$” and secondly, you are right, I had to make an initial commit on the master branch. Now it works.
Best Regards,
Dani