2013-02-06 54 views
5

मैं यहां दिए गए निर्देशों का पालन कर रहा हूँ:GitLab sidekiq में नाकाम रहने के परीक्षण

https://github.com/gitlabhq/gitlabhq/blob/4-1-stable/doc/install/databases.md

जब मैं परीक्षण चलाने के लिए प्रयास करें:

sudo -u gitlab -H bundle exec rake gitlab:env:info RAILS_ENV=production 
sudo -u gitlab -H bundle exec rake gitlab:check RAILS_ENV=production 

पहले टेस्ट नारंगी हेडर देता है, दूसरे टेस्ट एक से पता चलता साइडकीक के साथ त्रुटि:

Checking Sidekiq ...  

Running? ... no 
    Try fixing it: 
    sudo -u gitlab -H bundle exec rake sidekiq:start 
    For more information see: 
    doc/install/installation.md in section "Install Init Script" 
    see log/sidekiq.log for possible errors 
    Please fix the error above and rerun the checks. 
Checking Sidekiq ... Finished 

जब मैंचलाता हूं 0, मैं निम्नलिखित त्रुटि मिलती है:

rake aborted! 
cannot load such file -- rb-inotify 
/home/gitlab/gitlab/config/application.rb:9:in `<top (required)>' 
/home/gitlab/gitlab/Rakefile:5:in `require' 
/home/gitlab/gitlab/Rakefile:5:in `<top (required)>' 
(See full trace by running task with --trace) 

जब मैं ट्रेस चलाने के लिए, मैं निम्नलिखित उत्पादन प्राप्त करें:

rake aborted! 
cannot load such file -- rb-inotify 
/usr/local/lib/ruby/gems/1.9.1/gems/bundler-1.2.3/lib/bundler/runtime.rb:68:in `require' 
/usr/local/lib/ruby/gems/1.9.1/gems/bundler-1.2.3/lib/bundler/runtime.rb:68:in `block (2  levels) in require' 
/usr/local/lib/ruby/gems/1.9.1/gems/bundler-1.2.3/lib/bundler/runtime.rb:66:in `each' 
/usr/local/lib/ruby/gems/1.9.1/gems/bundler-1.2.3/lib/bundler/runtime.rb:66:in `block in require' 
/usr/local/lib/ruby/gems/1.9.1/gems/bundler-1.2.3/lib/bundler/runtime.rb:55:in `each' 
/usr/local/lib/ruby/gems/1.9.1/gems/bundler-1.2.3/lib/bundler/runtime.rb:55:in `require' 
/usr/local/lib/ruby/gems/1.9.1/gems/bundler-1.2.3/lib/bundler.rb:128:in `require' 
/home/gitlab/gitlab/config/application.rb:9:in `<top (required)>' 
/home/gitlab/gitlab/Rakefile:5:in `require' 
/home/gitlab/gitlab/Rakefile:5:in `<top (required)>' 
/home/gitlab/gitlab/vendor/bundle/ruby/1.9.1/gems/rake-10.0.3/lib/rake/rake_module.rb:25:in `load' 
/home/gitlab/gitlab/vendor/bundle/ruby/1.9.1/gems/rake-10.0.3/lib/rake/rake_module.rb:25:in `load_rakefile' 
/home/gitlab/gitlab/vendor/bundle/ruby/1.9.1/gems/rake-10.0.3/lib/rake/application.rb:583:in `raw_load_rakefile' 
/home/gitlab/gitlab/vendor/bundle/ruby/1.9.1/gems/rake-10.0.3/lib/rake/application.rb:89:in `block in load_rakefile' 
/home/gitlab/gitlab/vendor/bundle/ruby/1.9.1/gems/rake-10.0.3/lib/rake/application.rb:160:in `standard_exception_handling' 
/home/gitlab/gitlab/vendor/bundle/ruby/1.9.1/gems/rake-10.0.3/lib/rake/application.rb:88:in `load_rakefile' 
/home/gitlab/gitlab/vendor/bundle/ruby/1.9.1/gems/rake-10.0.3/lib/rake/application.rb:72:in `block in run' 
/home/gitlab/gitlab/vendor/bundle/ruby/1.9.1/gems/rake-10.0.3/lib/rake/application.rb:160:in `standard_exception_handling' 
/home/gitlab/gitlab/vendor/bundle/ruby/1.9.1/gems/rake-10.0.3/lib/rake/application.rb:70:in `run' 
/home/gitlab/gitlab/vendor/bundle/ruby/1.9.1/gems/rake-10.0.3/bin/rake:33:in `<top (required)>' 
/home/gitlab/gitlab/vendor/bundle/ruby/1.9.1/bin/rake:23:in `load' 
/home/gitlab/gitlab/vendor/bundle/ruby/1.9.1/bin/rake:23:in `<main>' 

मैं पहले से ही मैन्युअल रूप से समस्या को दूर करने rb-inotify स्थापित करने का प्रयास किया:

sudo gem install rb-inotify 

यह कहता है कि यह सफल है, लेकिन परीक्षण अभी भी काम नहीं करते हैं! कृपया सलाह दें! धन्यवाद

उत्तर

7

आदेश इस तरह का:

sudo -u gitlab -H bundle exec rake sidekiq:start 

न केवल जरूरत है gitlab क्लोन रेपो में चलाने के लिए, लेकिन यह भी एक RAILS_ENV=production जरूरत है ठीक ढंग से काम करने के लिए:

sudo -u gitlab -H bundle exec rake sidekiq:start RAILS_ENV=production 

0 देखें:

  • Error: no such file to load -- rb-inotify when running rake (as seen in #1752)
  • Problem: task run in wrong environment
  • Solution: add RAILS_ENV=production to the end of the command
2

स्पष्ट रूप से मैं इसे गलत तरीके से चला रहा था। यह चल रहा है इस तरह से इसे हल:

sudo -u gitlab -H bundle exec rake gitlab:check RAILS_ENV=production 

ट्यूटोरियल की जरूरत है अद्यतन करने की