Passenger: Cannot Load Such File Rubygems/Builder

Passenger: cannot load such file rubygems/builder

Updated instructions:

$ gem install passenger --version 4.0.0.rc6
$ passenger-install-apache2-module

Building passenger apache2 module: no such file to load -- rubygems builder

I used the newest passenger version (actually 4.0.0.rc4) from git repository and created a gem. Using this gem worked fine.

git clone https://github.com/FooBarWidget/passenger.git
cd passenger
gem build passenger.gemspec
gem install passenger-*.gem

After that you can build the apache2 plugin using passenger-install-apache2-module.

cannot load such file -- bundler/setup (LoadError)

It could be that there was a previous Ruby env installed on your system prior to your installation of 2.0? This might have had an existing GEM_PATH that lead to the /1.8 directory which the installation of version 2.0 simply kept.

The problem you where likely having, then, was that Passenger/Apache was looking in the /2.0 directory when in fact the gems were in the /1.8 directory. Your explicitly telling apache to use the /1.8 directory thus makes sense to fix the problem.

SetEnv GEM_HOME /usr/lib/ruby/gems/1.8

You might also try using the Ruby Version Manager to handle multiple Ruby envs.

Some things I found in Google:

  • New to Ruby and am having trouble with LOAD_PATH
  • http://weblog.rubyonrails.org/2009/9/1/gem-packaging-best-practices/
  • http://guides.rubygems.org/faqs/

Passenger RVM Error: cannot load such file -- bundler/setup

You have

deployment@currienet:/$ which ruby
/home/deployment/.rvm/rubies/ruby-1.9.3-p194/bin/ruby

and

PassengerRuby /usr/local/bin/ruby

this is not what you want. rvm has an option to set up an interpreter to use as passenger's default interpreter. https://rvm.io/integration/passenger/

Also (seeing your last edit) maybe you needto install rvm system-wide, as passenger will run as root.

strange error with passenger

This is the key to your error: no such file to load -- bundler/setup That suggests that Bundler is not installed on the server.

You say that bundler runs fine, not sure whether you mean that it runs from the console on the server - but it's not running for your passenger. So perhaps your passenger settings are pointing to a different Ruby installation, and bundler is not setup for that.

I'd start there.

Passenger-Sinatra: rack/showexceptions (LoadError)

Skydan's question pointed me in the right direction. I was manually installing each gem instead of using:

$ bundle install

Afterwords my error logs finally started changing, but I was still using Sintara-Base 1.0. Once I updated with $bundle update my application finally loaded.



Related Topics



Leave a reply



Submit