gitlabhq/gitlabhq — pull request #2947 by nafu (2013-02-08 18:45:34+00:00)
Title: Update command to execute as git user

sudo chmod -R ug+rwX,o-rwx /home/git/repositories/
sudo chown -R git:git /home/git/repositories/

From the above conditions,

find /home/git/repositories -type d -print0

should be executed by git user or group.