1
votes

I have to use bluehost shared hosting for some reason. I upgraded ruby to version 2.1.1 and Rails to version 4.2.2 (Following this article http://www.haydonryan.com/installing-ruby-2-1-1p76-and-rails-4-0-4-on-bluehost/).

Then I uploaded my application and followed instructions provided by Bluehost at https://my.bluehost.com/cgi/help/rails

Now when I go to the domain obortunity.org I get this error message:-

Ruby (Rack) application could not be started

Error message: Could not find rake-11.3.0 in any of the sources (Bundler::GemNotFound)

Exception class: PhusionPassenger::UnknownError

Application root: /home4/obortuni/rails_apps/obortunity

Backtrace:

0 /usr/lib64/ruby/gems/1.9.3/gems/bundler-1.3.5/lib/bundler/spec_set.rb 92 in block in materialize' 1 /usr/lib64/ruby/gems/1.9.3/gems/bundler-1.3.5/lib/bundler/spec_set.rb 85 inmap!' 2 /usr/lib64/ruby/gems/1.9.3/gems/bundler-1.3.5/lib/bundler/spec_set.rb 85 in materialize' 3 /usr/lib64/ruby/gems/1.9.3/gems/bundler-1.3.5/lib/bundler/definition.rb 114 inspecs' 4 /usr/lib64/ruby/gems/1.9.3/gems/bundler-1.3.5/lib/bundler/definition.rb 159 in specs_for' 5 /usr/lib64/ruby/gems/1.9.3/gems/bundler-1.3.5/lib/bundler/definition.rb 148 inrequested_specs' 6 /usr/lib64/ruby/gems/1.9.3/gems/bundler-1.3.5/lib/bundler/environment.rb 18 in requested_specs' 7 /usr/lib64/ruby/gems/1.9.3/gems/bundler-1.3.5/lib/bundler/runtime.rb 13 insetup' 8 /usr/lib64/ruby/gems/1.9.3/gems/bundler-1.3.5/lib/bundler.rb 120 in setup' 9 /etc/httpd/modules/passenger/lib/phusion_passenger/utils.rb 326 inprepare_app_process' 10 /etc/httpd/modules/passenger/lib/phusion_passenger/rack/application_spawner.rb 156 in block in initialize_server' 11 /etc/httpd/modules/passenger/lib/phusion_passenger/utils.rb 563 inreport_app_init_status' 12 /etc/httpd/modules/passenger/lib/phusion_passenger/rack/application_spawner.rb 154 in initialize_server' 13 /etc/httpd/modules/passenger/lib/phusion_passenger/abstract_server.rb 204 instart_synchronously' 14 /etc/httpd/modules/passenger/lib/phusion_passenger/abstract_server.rb 180 in start' 15 /etc/httpd/modules/passenger/lib/phusion_passenger/rack/application_spawner.rb 129 instart' 16 /etc/httpd/modules/passenger/lib/phusion_passenger/spawn_manager.rb 253 in block (2 levels) in spawn_rack_application' 17 /etc/httpd/modules/passenger/lib/phusion_passenger/abstract_server_collection.rb 132 inlookup_or_add' 18 /etc/httpd/modules/passenger/lib/phusion_passenger/spawn_manager.rb 246 in block in spawn_rack_application' 19 /etc/httpd/modules/passenger/lib/phusion_passenger/abstract_server_collection.rb 82 inblock in synchronize' 20 prelude> 10:in synchronize' 21 /etc/httpd/modules/passenger/lib/phusion_passenger/abstract_server_collection.rb 79 insynchronize' 22 /etc/httpd/modules/passenger/lib/phusion_passenger/spawn_manager.rb 244 in spawn_rack_application' 23 /etc/httpd/modules/passenger/lib/phusion_passenger/spawn_manager.rb 137 inspawn_application' 24 /etc/httpd/modules/passenger/lib/phusion_passenger/spawn_manager.rb 275 in handle_spawn_application' 25 /etc/httpd/modules/passenger/lib/phusion_passenger/abstract_server.rb 357 inserver_main_loop' 26 /etc/httpd/modules/passenger/lib/phusion_passenger/abstract_server.rb 206 in start_synchronously' 27 /etc/httpd/modules/passenger/helper-scripts/passenger-spawn-server 99 in '

For some reason Passenger is stuck on previous version of ruby which comes default in bluehost shared hosting. I tried 3-4 hours searching for a possible solution but couldn't find any.

Really looking forward for someones help. Thanks

1

1 Answers

0
votes

I did not work with bluehost before, but here are few suggestions, hope they can help:

  1. You can try to check where ruby version is set for Passenger. It depends how it is running on bluehost, if it is nginx - you can try to specify ruby version explicitly in webapp.conf file. If it is apache (did not work with it directly) - there should be it's own configuration file, where you can try to set the version explicitly

https://www.phusionpassenger.com/library/config/apache/reference/

  1. If the previous point did not help I would try to edit .bashrc file, not sure if it can be a problem (as I am using rvm), but it sounds strange for me:

    In setup article you provided is stated to edit .bashrc file:

    export GEM_PATH=$GEM_HOME:/lib64/ruby/gems/1.9.3 - could you check what you have there? If you upgraded to new ruby - probably path to ruby 2.1.1 gems folder should be specified.