Last Updated: February 25, 2016
·
2.44K
· williamn

Using rbenv and rbenv-gemset with Passenger in Production

In order to make Passenger acknowledge your project Ruby version and gem installation path, add something like this in to your virtual host configuration

PassengerRuby /home/user/.rbenv/versions/1.8.7-p370/bin/ruby
SetEnv GEM_PATH /home/user/.rbenv/versions/1.8.7-p370/gemsets/myapp

1 Response
Add your response

For nginx server try somthing like :

location @passenger {
  passenger_enabled on;
  passenger_app_env production;
  passenger_set_cgi_param GEM_PATH "/home/user/.rbenv/versions/1.8.7-p370/gemsets/myapp";
}
over 1 year ago ·