Using Ruby On Rails under Linux can make the maintenance and development of web applications more convenient, allowing developers to focus more on the logical structure of the system, before use Need to configure the Ruby On Rails development environment first, the following small series will introduce you how to configure Ruby On Rails development environment under Ubuntu 12.04.
Ubuntu 12.04 + Ruby 2.0 + Rails 3.2.13
1, the system needs to install the package
$ sudo apt-get install -y build-essential openssl Curl libcurl3-dev libreadline6 libreadline6-dev git zlib1g zlib1g-dev libssl-dev libyaml-dev libxml2-dev libxslt-dev autoconf automake libtool imagemagick libmagickwand-dev libpcre3-dev libsqlite3-dev libmysql-ruby libmysqlclient-dev
2, install RVM
$ curl -L https://get.rvm.io |
Bash -s stable
After installing RVM successfully,
Then, load the RVM environment (newly open Termal will not do this, it will be automatically reloaded)
$ source ~/.rvm/scripts/rvm
Check if it is installed correctly
$ rvm -v
rvm 1.17.3 (stable) by Wayne E. Seguin [email protected]", Michal Papis "[email protected]" [https://rvm.io/]
3, Install Ruby Environment with RVM
# Replace Ruby Download Address Go to the domestic Taobao mirror server $ sed -i.bak ‘s! Ftp.ruby-lang.org/pub/ruby! Ruby.taobao.org/mirrors/ruby! ’ $rvm_path/config/db
# Install readline package $ rvm pkg install readline
# Install Ruby 2.0.0$ rvm install 2.0.0 --with-readline-dir=$ Rvm_path/usr
4, set the Ruby version
$ rvm 2.0.0 --default
Test is correct
$ ruby -v
ruby 2.0.0p0 (2013-02-24 revision 39474)[x86_64-darwin12.3.0]
$ gem -v
2.0.0
$ gem Source -r https://rubygems.org/
$ gem source -a http://ruby.taobao.org
5, install Rails environment
$ gem Install bundler rails
Test if the installation is correct
$ bundle -v
Bundler version 1.0
$ rails -v
Rails 3.2 .13
6. Install MySQL
$ sudo apt-get install mysql-server mysql-client //Keep in mind the password you entered during installation $ sudo apt-get install libmysql-ruby libmysqlclient- Dev
$ gem install mysql2
View Gem package gem lis t
The above is how Ubuntu built the Ruby On Rails development environment. You need to install RVM, install the Ruby environment, install the Rails environment, and finally install MySQL.
System virus in addition to browsing the web, the U disk is also the source of the virus, if you fin
The dd command is very useful on Linux systems, Linux commands that can copy files.
After installing CentOS 5.5 system, some people cant access the Internet. After tes
Linux multi-path refers to the connection between the host and the hard disk, and also includes the
How to solve the garbled problem after SecureCRT connects to Linux server
How to install and use http_load to stress test the server in Linux
How to install and configure Git in Ubuntu system
Linux system view wwn number trick
Linux how to use the text processing tool awk
How Linux implements remote control of shell commands
Linux how to use the whereis command to quickly find the file
How to install and use Glances in Linux
Notes on using the kill command in Linux
How to achieve automatic connection of broadband when Windows 8.1 is started
Final Fantasy Zero HD first chapter BOSS how to play the first chapter BOSS clearance Raiders
Teach you to have a command prompt window also have transparency effects
Cancel Win7 system shutdown patch reminder
How to install Windows XP under Windows Vista to achieve dual system problems
The epoch-making system revolution: Commemorating the 5th anniversary of Vista's release
Win7 system computer boot speed is slow to show the code how to do
U disk inserted win7 system computer can not automatically play the solution
Let's see: the system can't display thumbnail tips
Win10/win8/win8.1 disk occupancy rate of 50% or 100% is going on