2014-11-07 17 views
6

Sunucuda Gitlab gitlab_7.4.3-omnibus.5.1.0.ci-1_amd64.deb'u yüklemeyi denedim.GitLab reconfigure Hata: 'create' eylemini çalıştır 'user [git]'

sudo gitlab-ctl reconfigure'u çalıştırdığımda bir hata oluştu.

hatası log geçerli: Başka

[2014-11-07T12:26:33+08:00] INFO: Forking chef instance to converge... 
[2014-11-07T12:26:33+08:00] INFO: *** Chef 11.12.2 *** 
[2014-11-07T12:26:33+08:00] INFO: Chef-client pid: 17502 
[2014-11-07T12:26:35+08:00] INFO: Setting the run_list to ["recipe[gitlab]"] from CLI options 
[2014-11-07T12:26:35+08:00] INFO: Run List is [recipe[gitlab]] 
[2014-11-07T12:26:35+08:00] INFO: Run List expands to [gitlab] 
[2014-11-07T12:26:35+08:00] INFO: Starting Chef Run for R710 
[2014-11-07T12:26:35+08:00] INFO: Running start handlers 
[2014-11-07T12:26:35+08:00] INFO: Start handlers complete. 
[2014-11-07T12:26:35+08:00] WARN: Cloning resource attributes for directory[/var/opt/gitlab] from prior resource (CHEF-3694) 
[2014-11-07T12:26:35+08:00] WARN: Previous directory[/var/opt/gitlab]: /opt/gitlab/embedded/cookbooks/gitlab/recipes/default.rb:40:in `from_file' 
[2014-11-07T12:26:35+08:00] WARN: Current directory[/var/opt/gitlab]: /opt/gitlab/embedded/cookbooks/gitlab/recipes/users.rb:23:in `from_file' 
[2014-11-07T12:26:35+08:00] WARN: Cloning resource attributes for directory[/var/opt/gitlab/gitlab-rails/etc] from prior resource (CHEF-3694) 
[2014-11-07T12:26:35+08:00] WARN: Previous directory[/var/opt/gitlab/gitlab-rails/etc]: /opt/gitlab/embedded/cookbooks/gitlab/recipes/gitlab-rails.rb:37:in `block in from_file' 
[2014-11-07T12:26:35+08:00] WARN: Current directory[/var/opt/gitlab/gitlab-rails/etc]: /opt/gitlab/embedded/cookbooks/gitlab/definitions/unicorn_config.rb:21:in `block in from_file' 
[2014-11-07T12:26:35+08:00] WARN: Cloning resource attributes for service[unicorn] from prior resource (CHEF-3694) 
[2014-11-07T12:26:35+08:00] WARN: Previous service[unicorn]: /opt/gitlab/embedded/cookbooks/gitlab/recipes/default.rb:64:in `block in from_file' 
[2014-11-07T12:26:35+08:00] WARN: Current service[unicorn]: /opt/gitlab/embedded/cookbooks/runit/definitions/runit_service.rb:191:in `block in from_file' 
[2014-11-07T12:26:35+08:00] WARN: Cloning resource attributes for service[sidekiq] from prior resource (CHEF-3694) 
[2014-11-07T12:26:35+08:00] WARN: Previous service[sidekiq]: /opt/gitlab/embedded/cookbooks/gitlab/recipes/default.rb:64:in `block in from_file' 
[2014-11-07T12:26:35+08:00] WARN: Current service[sidekiq]: /opt/gitlab/embedded/cookbooks/runit/definitions/runit_service.rb:191:in `block in from_file' 

================================================================================ 
[31mError executing action `create` on resource 'user[git]' 
================================================================================ 


Mixlib::ShellOut::ShellCommandFailed 
------------------------------------ 
Expected process to exit with [0], but received '8' 
---- Begin output of ["usermod", "-s", "/bin/sh", "-d", "/var/opt/gitlab", "git"] ---- 
STDOUT: 
STDERR: usermod: user git is currently logged in 
---- End output of ["usermod", "-s", "/bin/sh", "-d", "/var/opt/gitlab", "git"] ---- 
Ran ["usermod", "-s", "/bin/sh", "-d", "/var/opt/gitlab", "git"] returned 8 


Resource Declaration: 
--------------------- 
# In /opt/gitlab/embedded/cookbooks/gitlab/recipes/users.rb 

34: user gitlab_username do 
35: shell node['gitlab']['user']['shell'] 
36: home gitlab_home 
37: uid node['gitlab']['user']['uid'] 
38: gid gitlab_group 
39: system true 
40: end 
41: 



Compiled Resource: 
------------------ 
# Declared in /opt/gitlab/embedded/cookbooks/gitlab/recipes/users.rb:34:in `from_file' 

user("git") do 
    action :create 
    supports {:manage_home=>false, :non_unique=>false} 
    retries 0 
    retry_delay 2 
    guard_interpreter :default 
    username "git" 
    gid 1014 
    home "/var/opt/gitlab" 
    shell "/bin/sh" 
    system true 
    cookbook_name :gitlab 
    recipe_name "users" 
end 



[2014-11-07T12:26:35+08:00] INFO: Running queued delayed notifications before re-raising exception 
[2014-11-07T12:26:35+08:00] ERROR: Running exception handlers 
[2014-11-07T12:26:35+08:00] ERROR: Exception handlers complete 
[2014-11-07T12:26:35+08:00] FATAL: Stacktrace dumped to /opt/gitlab/embedded/cookbooks/cache/chef-stacktrace.out 
[2014-11-07T12:26:35+08:00] ERROR: user[git] (gitlab::users line 34) had an error: Mixlib::ShellOut::ShellCommandFailed: Expected process to exit with [0], but received '8' 
---- Begin output of ["usermod", "-s", "/bin/sh", "-d", "/var/opt/gitlab", "git"] ---- 
STDOUT: 
STDERR: usermod: user git is currently logged in 
---- End output of ["usermod", "-s", "/bin/sh", "-d", "/var/opt/gitlab", "git"] ---- 
Ran ["usermod", "-s", "/bin/sh", "-d", "/var/opt/gitlab", "git"] returned 8 
[2014-11-07T12:26:36+08:00] FATAL: Chef::Exceptions::ChildConvergeError: Chef run process exited unsuccessfully (exit code 1) 

şey geçerli:

benim günlüğüne usermod: user git is currently logged in gördü. Ve zaten sunucumda git isimli bir kullanıcı var. Yani herhangi bir sorun var mı, nasıl düzeltilir?

Çok teşekkürler!

cevap

15

git adında bir kullanıcınız olduğu gerçeği büyük olasılıkla ortaya çıkıyor: GitLab için ayrılmış bir kullanıcıya ihtiyacınız olacak.

sen as explained on the README yapmaya denediniz: Varsayılan olarak

, öğrencilerin-gitlab web arayüzüne Git gitlab-kabuk giriş, Git veri kendisi mülkiyet ve SSH URL nesil için kullanıcı adını git kullanır. Benzer şekilde, Git verilerinin grup sahipliği için git grubu kullanılır. Aşağıdaki satırları /etc/gitlab/gitlab.rb'a ekleyerek kullanıcı ve grubu değiştirebilirsiniz. değişim için

user['username'] = "gitlab" 
user['group'] = "gitlab" 

Run sudo gitlab-ctl reconfigure etkili olması.

+1

Cool !! Bunu fark etmedim. Çok teşekkürler! – Daizy

+0

Teşekkürler! ağrılı deneme ve hata sonrası çalışıyor. Benim durumumda bunu yeniden yaratmam gerekiyor .. sudo gitlab-rake gitlab: setup RAILS_ENV = üretim (ubuntu 14.04'ü vmimde çalıştırıyorum) – syyu

3

Önceki yanıt doğru, zaten bir kullanıcı kullanıcısınız. Bunun nedeni, zaten onu oluşturduğunuz veya gitlab yüklemenizin çalıştığı için olabilir. Bu durumda, ihtiyacınız olmayan yeni bir kullanıcı oluşturuyor olacaksınız.

Dene: değişikliğin etkinleşmesi için

sudo service gitlab stop 

ve çalıştırın

sudo gitlab-ctl reconfigure 

.