简体   繁体   中英

Passenger stand alone uses wrong ruby version?

Hello im using rails 4 with rvm - ruby verison 2.0. But when i try to start passenger (stand alone) im getting syntax-errors.

It tells me:

Ruby interpreter command
/usr/bin/ruby1.8

How can i change it to the rvm 2.0 version?

you need to use ruby first:

rvm use ruby

it might display additional instructions - make sure to read them

I had the same problem: passenger standalone uses nginx, and after upgrading my app to use ruby 2.1.1 (specified in the .ruby-version), I saw similar errors.

On my production server, I know where the nginx configuration lives, so I could fix the path to the ruby interpreter.

However on the standalone setup I couldn't find it in less a minute, so I did a gem uninstall passenger followed by gem install passenger to have it recompile nginx.

Now it works, at least until the next ruby interpreter bump.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM