2

I have been trying to install GitLab on CentOS 5.x, but I am stuck now and google's are confusing.

I have been following this install guide (currently stuck here)

After running bundle exec rake gitlab:app:status RAILS_ENV=production for the secund time I get this output:

Starting diagnostic
config/database.yml............exists
config/gitlab.yml............exists
/home/git/repositories/............missing
rake aborted!
unexpected return

The relevant part from /home/gitlab/gitlab/config/gitlab.yml is this (server has custom shh port):

git_host:
  system: gitolite___
  admin_uri: git@localhost:gitolite-admin
  base_path: /home/git/repositories/
  host: localhost
  git_user: git
  port: 2134

Folder permissions are drwxrwx--- 4 git git 4096 Jul 20 07:12 repositories and the files inside are (gitlab user is in git group):

drwxrwx--- 8 git git 4096 Jul 20 04:22 gitolite-admin.git
drwxrwx--- 7 git git 4096 Jul 20 04:22 testing.git

Thing, even if I change the base_path value in config/gitlab.yml, it keeps trying to look up the same folder.

Only possible directions for the solution, that I found on google, indicated, that it is somehow related to SElinux. The suggested command was: find . -print0 |xargs -0 -n 1 sudo setfattr -h -x security.selinux. But i have no clue where to execute it and it tells me that command setfattr not found .. or something. Also, I kinda doubt, that unchanging configuration might too be affected by SElinux.

What to do ?

tftd
  • 1,498
  • 7
  • 25
  • 40
teresko
  • 164
  • 1
  • 10

2 Answers2

1

Maybe you did not run the rake command as your gitlab user? As in:

sudo -u gitlab bundle exec rake gitlab:app:status RAILS_ENV=production

Had a similar problem, seeing other settings from gitlab.yml just not being applied...

Kenny Rasschaert
  • 9,045
  • 3
  • 42
  • 58
Philzen
  • 121
  • 3
0

You mention:

Thing, even if I change the base_path value in config/gitlab.yml, it keeps trying to look up the same folder.

If you look at the config/initializers/1_settings.rb program:

def git_base_path
      git_host['base_path'] || '/home/git/repositories/'
end

So this is your real issue here (before starting tweaking the folder permissions): gitlab somehow ignores your config/gitlab.yml setting.
Double-check for any typo in it, and make sure it is taken into account at all (by removing it for instance, to see if gitlab complains about that file missing).

VonC
  • 2,683
  • 5
  • 30
  • 49
  • I have v2.6.3 but there is no such file – teresko Jul 20 '12 at 21:55
  • @teresko try installing from `master`, following https://github.com/gitlabhq/gitlabhq/blob/master/doc/installation.md, and see if the issue persists. – VonC Jul 20 '12 at 22:37