阅读背景:

如何在Cloud9上安装旧版本的Ruby

来源:互联网 

I have a source code that I want to test on Cloud9 hosting (I have premium account). However, the problem is that the source code is bade on Ruby 1.8, mysql-essential-5.0 and other old libraries.

我有一个源代码,我想在Cloud9托管上测试(我有高级帐户)。但是,问题是源代码是对Ruby 1.8,mysql-essential-5.0和其他旧库的抨击。

How can I create a plain VM on cloud9 and install ruby and other version by myself ? So far all i see that all vms are pre-configured with ruby 4

如何在cloud9上创建普通虚拟机并自行安装ruby和其他版本?到目前为止,我发现所有vms都预先配置了ruby 4

1 个解决方案

#1


Cloud9 IDE comes with rvm preinstalled, so this is nice. Otherwise, all VM are pre-configured with Ruby 2.1.5 (not 4) and Rails 4.1.6

Cloud9 IDE预装了rvm,所以很不错。否则,所有VM都预先配置了Ruby 2.1.5(不是4)和Rails 4.1.6

The only thing you have to do in your console is :

您在控制台中唯一需要做的就是:

# Check your actual Ruby version
ruby -v
# ruby 2.1.5p273 (2014-11-13 revision 48405) [x86_64-linux] 

# Install ruby 1.8 (if it's not already done)
rvm install ruby-1.8

# Switch ruby version
rvm use 1.8

For MySQL I would first do an uninstallation of your current version of mysql with sudo apt-get uninstall mysql* and then install it from source. You can check this link for more info.

对于MySQL,我首先使用sudo apt-get uninstall mysql *卸载当前版本的mysql,然后从源代码安装它。您可以查看此链接以获取更多信息。


分享到: