14

I am using Gitlab and I am trying to follow these instructions to upgrade my gitolite v2 to v3:

"If this issue occurs in 2.9.x you should reinstall gitolite.

1) backup all repositories. Just copy /home/git/repositories/* elsewhere.

2) Install new gitolite. See https://github.com/gitlabhq/gitlabhq/blob/master/doc/installation.md

3) copy repositories back.

4) sudo -u gitlab -H bundle exec rake gitlab:gitolite:update_keys && sudo -u gitlab -H bundle exec rake gitlab:gitolite:update_repos

That's all.

That steps also related to users who wants to update gitolite v2 to v3"

My Gemfile and Gemfile.lock have rb-inotify in them as shown below:

gitlabhq@build:~/gitlabhq$ grep notify Gemfile
gem 'rb-inotify', :require => linux_only('rb-inotify')
gitlabhq@build:~/gitlabhq$ grep notify Gemfile.lock
rb-inotify (0.8.8)
rb-inotify

I am trying to update my keys and repos using the following commands but I always get the error "no such file to load --rb-inotify"

gitlabhq@geminibuild:~/gitlabhq$ sudo -u gitlabhq -H bundle exec rake gitlab:gitolite:update_keys
rake aborted!
no such file to load -- rb-inotify
(See full trace by running task with --trace)

I've tried to do a bundle install , and the list of 'Using " does not contain the rb-notify gem.

I've tried to install the rb-inotify gem like so:

sudo -u gitlabhq gem install rb-inotify

I've wiped the Gemfile.lock file and then run:

sudo -u gitlabhq bundle install

Still no luck.

How can I get Gitlab to recognize and use rb-inotify. Thank you -

3
  • Did you try to install ruby-inotify? github.com/aredridel/ruby-inotify (as suggested in stackoverflow.com/questions/8061881/ruby-loaderror-inotify)
    – VonC
    Commented Oct 23, 2012 at 14:39
  • Yes I cloned that repository and ran 'sudo gem install ruby-inotify' and received a success message but still get the same error with the 'sudo -u gitlab -H bundle exec rake gitlab:gitolite:update_keys' command
    – PhilBot
    Commented Oct 23, 2012 at 14:53
  • Can you try and remove any 'inotify' reference Gemfile and Gemfile.lock, to see if you can execute the rake command?
    – VonC
    Commented Oct 23, 2012 at 15:27

2 Answers 2

19

Recognizing that this is a bit old, I thought I'd leave something for posterity. In order to make these calls work you simply need to append:

RAILS_ENV=production

to your command. This is listed in the trouble shooting guide under the "Gitlab" section.

0
5

I seemed to have fixed it by running:

bundle install --without production
bundle install
1
  • 1
    FYI: The inotify gem is marked as development dependency therefore this works. A side effect is a lot of unused garbage. Alternatively you can add gem "rb-inotify" to the bottom of the Gemfile and run bundle install again (you have to do this on each update though until it is fixed) Commented Jan 17, 2013 at 16:29

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.