Install and configure RubyonRails on the Linux platform. Install ruby1.9-Linux general technology-Linux programming and kernel information. For more information, see the following. The production and Running Environments recommended by ruby on rails are Linux/FreeBSD/Unix, that is, Unix operating systems. They use lighttpd + FCGI solutions. I will take the Linux operating system, lighttpd + FCGI, MySQL database as an example to explain how to compile and install the source code.
Before installation, check that the gcc compiler has been installed in the Linux operating system. Otherwise, use the Linux installation CD to install the gcc compiler first:
Gcc? V
If the gcc version is returned, the gcc is correctly installed.
In some Linux releases, the MacOSX operating system comes with a Ruby parser, but I still recommend that you download the ruby source code for compilation and installation. On the one hand, you can customize the path for ruby installation, and on the other hand, you can add more features during the compilation process.
Ruby source code can be downloaded from the Ruby Official Website: http://www.ruby-lang.org/en/downloads/
Download the source code package to the local Linux host, decompress it, enter the directory, configure, compile, and install it:
Tar xzvf ruby-1.9.0.tar.gz
Cd ruby-1.9.0
./Configure? Prefix =/usr/local/ruby
Sudo make
Sudo make install
To view all the configure parameters, you can:
./Configure? Help | more
If you do not customize the installation directory, it will be installed under the/usr/local directory by default. However, we recommend that you customize a ruby installation directory, such as/usr/local/ruby, to facilitate future upgrades without mixing with other software in the operating system.
After installation, modify the PATH of the operating system and add/usr/local/ruby/bin:
Export PATH =/usr/local/ruby/bin: $ PATH
Place our self-installed ruby in front of the system PATH to avoid interference caused by the built-in ruby in the operating system. In Linux, the settings are generally placed in/etc/profile for global effect.
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service