Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
ruby 2.6.3 setup for centos 6.x
#!/usr/bin/env bash
# repository
cd /tmp
wget http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
rpm -Uvh epel-release-6-8.noarch.rpm
# system update
yum -y update
yum -y groupinstall "Development Tools"
yum -y install libxslt-devel libyaml-devel libxml2-devel gdbm-devel libffi-devel zlib-devel openssl-devel libyaml-devel readline-devel curl-devel openssl-devel pcre-devel git memcached-devel valgrind-devel mysql-devel ImageMagick-devel ImageMagick
# ruby 2.6.3
version=2.6.3
cd /usr/local/src
wget https://cache.ruby-lang.org/pub/ruby/2.6/ruby-$version.tar.gz
tar zxvf ruby-$version.tar.gz
cd ruby-$version
./configure
make
make install
# ruby-gems
version=3.0.3
cd ..
wget https://rubygems.org/rubygems/rubygems-$version.tgz
tar zxvf rubygems-$version.tgz
cd rubygems-$version
/usr/local/bin/ruby setup.rb
# chef-solo
gem install bundler chef ruby-shadow --no-ri --no-rdoc
@zaq111

This comment has been minimized.

Copy link

zaq111 commented Jun 14, 2015

thanks

@humbass

This comment has been minimized.

Copy link

humbass commented Nov 22, 2015

thank you.

@karso

This comment has been minimized.

Copy link

karso commented May 20, 2016

It worked great. Thanks!

@7411649182

This comment has been minimized.

Copy link

7411649182 commented Jul 14, 2017

still, i am seeing 2.1 version only after installing it

@zakir-synectiks

This comment has been minimized.

Copy link

zakir-synectiks commented Jul 11, 2018

Thanks

@leo-licon

This comment has been minimized.

Copy link

leo-licon commented Sep 27, 2018

Great thanks! I used:

yum -y install openssl-devel

instead

yum -y install libxslt-devel libyaml-devel libxml2-devel gdbm-devel libffi-devel zlib-devel openssl-devel libyaml-devel readline-devel curl-devel openssl-devel pcre-devel git memcached-devel valgrind-devel mysql-devel ImageMagick-devel ImageMagick

and worked fine

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.