Closed DnR-iData closed 9 years ago
In files : gitlab.background_jobs.plist & gitlab.web.plist
the both on line 13 I have to change the 'bundle' directory to the relative directory.
-<string>bundle</string>
+<string>/Users/git/.rbenv/shims/bundle</string>
I don't know if it's the good choice, what do you think about this diff ?
I don't know why, but I need to have a first login with a user for the complete load of gitlab and after I can access to it. Any idea why ?
Thanks
Now that I've gotten to this point, I am having the same issue. In my log (for instance):
7/9/15 7:57:28.884 PM com.apple.xpc.launchd[1]: (gitlab.background_jobs[72004]) Service exited with abnormal code: 127
7/9/15 7:57:28.884 PM com.apple.xpc.launchd[1]: (gitlab.background_jobs) Service only ran for 0 seconds. Pushing respawn out by 10 seconds.
7/9/15 7:57:37.090 PM com.apple.xpc.launchd[1]: (gitlab.web[72012]) Service could not initialize: 14E46: xpcproxy + 13421 [1402][7D917364-B96E-3F93-B923-A89B5BF5736D]: 0x2
7/9/15 7:57:37.090 PM com.apple.xpc.launchd[1]: (gitlab.web) Service only ran for 0 seconds. Pushing respawn out by 10 seconds.
[...ad infinitum]
127
is command not found, I think, so I tried the idea from @DnR-iData to provide the full path, and it seems to be running, but occasionally returning code 1, which isn't terribly helpful.
I also admit I don't understand:
ProgramArguments
arrays in these plists should be in sync withstart
functions in scripts background_jobs and web.
Check gitlab-shell
$ sudo -u git /Users/git/gitlab-shell/bin/check
Check GitLab API access: FAILED: Failed to connect to internal API
Double-check environment configuration
$ sudo -u git -H bash -l -c 'bundle exec rake gitlab:env:info RAILS_ENV=production'
System information
System:
Current User: git
Using RVM: no
Ruby Version: 2.1.6p336
Gem Version: 2.2.3
Bundler Version:1.10.5
Rake Version: 10.4.2
Sidekiq Version:3.3.0
GitLab information
Version: 7.12.2
Revision: bf9c135
Directory: /Users/git/gitlab
DB Adapter: postgresql
URL: http://domain.com
HTTP Clone URL: http://domain.com/some-project.git
SSH Clone URL: git@domain.com:some-project.git
Using LDAP: no
Using Omniauth: no
GitLab Shell
Version: 2.6.3
Repositories: /Users/git/repositories/
Hooks: /Users/git/gitlab-shell/hooks/
Git: /usr/local/bin/git
Do a thorough check. Make sure everything is green.
$ sudo -u git -H bash -l -c 'bundle exec rake gitlab:check RAILS_ENV=production'
Checking GitLab Shell ...
GitLab Shell version >= 2.6.3 ? ... OK (2.6.3)
Repo base directory exists? ... yes
Repo base directory is a symlink? ... no
Repo base owned by git:git? ... yes
Repo base access is drwxrws---? ... yes
Satellites access is drwxr-x---? ... yes
hooks directories in repos are links: ... can't check, you have no projects
Running /Users/git/gitlab-shell/bin/check
Check GitLab API access: FAILED: Failed to connect to internal API
gitlab-shell self-check failed
Try fixing it:
Make sure GitLab is running;
Check the gitlab-shell configuration file:
sudo -u git -H editor /Users/git/gitlab-shell/config.yml
Please fix the error above and rerun the checks.
Checking GitLab Shell ... Finished
Checking Sidekiq ...
Running? ... yes
Number of Sidekiq processes ... 1
Checking Sidekiq ... Finished
Checking LDAP ...
LDAP is disabled in config/gitlab.yml
Checking LDAP ... Finished
Checking GitLab ...
Git configured with autocrlf=input? ... Trying to fix Git error automatically. ...Failed
Try fixing it:
sudo -u git -H "/usr/local/bin/git" config --global core.autocrlf "input"
For more information see:
doc/install/installation.md in section "GitLab"
Database config exists? ... yes
Database is SQLite ... no
All migrations up? ... yes
Database contains orphaned GroupMembers? ... no
GitLab config exists? ... yes
GitLab config outdated? ... no
Log directory writable? ... yes
Tmp directory writable? ... yes
Init script exists? ... no
Try fixing it:
Install the init script
For more information see:
doc/install/installation.md in section "Install Init Script"
Please fix the error above and rerun the checks.
Init script up-to-date? ... can't check because of previous errors
projects have namespace: ... can't check, you have no projects
Projects have satellites? ... can't check, you have no projects
Redis version >= 2.0.0? ... yes
Ruby version >= 2.0.0 ? ... yes (2.1.6)
Your git bin path is "/usr/local/bin/git"
Git version >= 1.7.10 ? ... no
Try fixing it:
Update your git to a version >= 1.7.10 from Unknown
Please fix the error above and rerun the checks.
Active users: 1
Checking GitLab ... Finished
Alas, it is not green. I tried checking the gitlab-shell configuration file, but it seemed to be as the walkthrough says it should be. Ideas?
I've tried others ProgramArguments for starting daemons. I think, when OS X try to start Web & Background_jobs (with root) the command is not in the right context, daemon try to start scripts with sh but I think they have to start with bash, here my diff :
gitlab.backup.plist between lines 13 & 17 :
-<string>bundle</string>
-<string>exec</string>
-<string>rake</string>
-<string>gitlab:backup:create</string>
-<string>RAILS_ENV=production</string>
+<string>bash</string>
+<string>-l</string>
+<string>-c</string>
+<string>bundle exec rake gitlab:backup:create RAILS_ENV=production</string>
gitlab.background_jobs.plist between lines 13 & 33 :
-<string>bundle</string>
-<string>exec</string>
-<string>sidekiq</string>
-<string>-q</string>
-<string>post_receive</string>
-<string>-q</string>
-<string>mailer</string>
-<string>-q</string>
-<string>system_hook</string>
-<string>-q</string>
-<string>project_web_hook</string>
-<string>-q</string>
-<string>gitlab_shell</string>
-<string>-q</string>
-<string>common</string>
-<string>-q</string>
-<string>default</string>
-<string>-e</string>
-<string>production</string>
-<string>-P</string>
-<string>tmp/pids/sidekiq.pid</string>
+<string>bash</string>
+<string>-l</string>
+<string>-c</string>
+<string>bundle exec sidekiq -q post_receive -q mailer -q system_hook -q project_web_hook -q gitlab_shell -q common -q default -e production -P tmp/pids/sidekiq.pid</string>
gitlab.web.plist between lines 13 & 19 :
-<string>bundle</string>
-<string>exec</string>
-<string>unicorn_rails</string>
-<string>-c</string>
-<string>config/unicorn.rb</string>
-<string>-E</string>
-<string>production</string>
+<string>bash</string>
+<string>-l</string>
+<string>-c</string>
+<string>bundle exec unicorn_rails -c config/unicorn.rb -E production</string>
I have this configuration & all start well (but I have to login first my user :( ) :
$ sudo -u git /Users/git/gitlab-shell/bin/check
Password:
Check GitLab API access: OK
Check directories and files:
/Users/git/repositories: OK
/Users/git/.ssh/authorized_keys: OK
Test redis-cli executable: redis-cli 3.0.2
Send ping to redis server: PONG
$ sudo -u git -H bash -l -c 'bundle exec rake gitlab:env:info RAILS_ENV=production'
(in /Users/git/gitlab)
System information
System:
Current User: git
Using RVM: no
Ruby Version: 2.1.6p336
Gem Version: 2.2.3
Bundler Version:1.10.5
Rake Version: 10.4.2
Sidekiq Version:3.3.0
GitLab information
Version: 7.12.2
Revision: 30bffd5
Directory: /Users/git/gitlab
DB Adapter: postgresql
URL: http://testgit.heva.local
HTTP Clone URL: http://testgit.heva.local/some-project.git
SSH Clone URL: git@testgit.heva.local:some-project.git
Using LDAP: no
Using Omniauth: no
GitLab Shell
Version: 2.6.3
Repositories: /Users/git/repositories/
Hooks: /Users/git/gitlab-shell/hooks/
Git: /usr/local/bin/git
sudo -u git -H bash -l -c 'bundle exec rake gitlab:check RAILS_ENV=production'
(in /Users/git/gitlab)
Checking GitLab Shell ...
GitLab Shell version >= 2.6.3 ? ... OK (2.6.3)
Repo base directory exists? ... yes
Repo base directory is a symlink? ... no
Repo base owned by git:git? ... yes
Repo base access is drwxrws---? ... yes
Satellites access is drwxr-x---? ... yes
hooks directories in repos are links: ... can't check, you have no projects
Running /Users/git/gitlab-shell/bin/check
Check GitLab API access: OK
Check directories and files:
/Users/git/repositories: OK
/Users/git/.ssh/authorized_keys: OK
Test redis-cli executable: redis-cli 3.0.2
Send ping to redis server: PONG
gitlab-shell self-check successful
Checking GitLab Shell ... Finished
Checking Sidekiq ...
Running? ... yes
Number of Sidekiq processes ... 1
Checking Sidekiq ... Finished
Checking LDAP ...
LDAP is disabled in config/gitlab.yml
Checking LDAP ... Finished
Checking GitLab ...
Git configured with autocrlf=input? ... yes
Database config exists? ... yes
Database is SQLite ... no
All migrations up? ... yes
Database contains orphaned GroupMembers? ... no
GitLab config exists? ... yes
GitLab config outdated? ... no
Log directory writable? ... yes
Tmp directory writable? ... yes
Init script exists? ... no
Try fixing it:
Install the init script
For more information see:
doc/install/installation.md in section "Install Init Script"
Please fix the error above and rerun the checks.
Init script up-to-date? ... can't check because of previous errors
projects have namespace: ... can't check, you have no projects
Projects have satellites? ... can't check, you have no projects
Redis version >= 2.0.0? ... yes
Ruby version >= 2.0.0 ? ... yes (2.1.6)
Your git bin path is "/usr/local/bin/git"
Git version >= 1.7.10 ? ... yes (2.4.5)
Active users: 1
Checking GitLab ... Finished
@bobtiki
I got the same result (code 1), but then I founded that file /Users/git/gitlab/.ruby-version contains 2.1.5
. But here must be 2.1.6
version!
Now all works correct!
p.s. Thx @DnR-iData ^_^
I removed launchdeamons for now. I have plan to rewrite them using /etc/inig.d/gitlab
.
I've created plist for the new version (with nginx).
Hi,
Links broken
The links of scripts background_jobs and web are broken. I think the are :
Daemons doesn't start
The gitlab.web & gitlab.backgrounds_jobs doesn't start. When I load & unload gitlab.web I have this error :
& the same for backgound_jobs :
If I try in command line all works perfectly :
& in another tab :
Stdout :
Need informations
I don't understand what does it mean :
Can you help a little please.
Thanks in advance