清除舊版(若是有的話)ruby
yum remove rubycurl
下載ruby源碼包並解壓url
curl --progress ftp://ftp.ruby-lang.org/pub/ruby/2.4/ruby-2.4.0.tar.gz | tar xzrem
ruby安裝源碼
cd ruby-2.4.0ftp
./configure淘寶
make && make install下載
安裝bundler gemyum
因爲AWS被中國長城關在門外沒法使用,修改ruby的源爲淘寶
gem sources -r https://rubygems.org/
gem sources -a https://ruby.taobao.org/
gem sources -l
gem install bundler make
添加如下軟鏈接,不然可能提示找不到
ln -s /usr/local/bin/ruby /usr/bin/ruby ln -s /usr/local/bin/gem /usr/bin/gem ln -s /usr/local/bin/bundle /usr/bin/bundle