简体   繁体   中英

Can I downgrade my app to older versions of Ruby and Rails? How?

I just created a cool web app on my Mac using Ruby 2.2.3p173 and Rails 4.2.5.

The place where I would like to host it only has up to Ruby 2.0.0 and Rails 4.2.4 installed on their shared hosting platforms.

What should I do? Can I downgrade Ruby and Rails? If so, what is the best way to go about it?

Thanks

Porting your app to an older Ruby and Rails would be a bad idea. Not only would you be exposing yourself to security holes that have been fixed in more recent releases ( Ruby 2.0 will be end of lifed on February 24, 2016 , and there have been important security patches since Rails 4.2.4 ), you would be swimming against the continuous pressure to upgrade exerted by the other gems you might want to use, documentation, etc.

There is probably nothing preventing you from installing a current version of Ruby in your own account on the hosting provider using a version manager like rbenv or rvm. (I recommend rbenv.) You are also probably free to install any gems you like (probably with bundler), including current versions of Rails.

If that hosting provider does prevent you from using or installing a newer Ruby or Rails, find a different hosting provider. That one will fail soon enough anyway.

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