How to install Ruby and Rails on Debian Linux using RVM

I’ve recently been sharpening my skills in various languages that I’ve used over the years. This has included programming in the specific language, but also setting up the development environment for that language.

This post describes the process of setting up a VirtualBox VM running Debian for doing Ruby on Rails development.

For those getting started with Rails, the Rails Guide is a great place to begin.

1. Install RVM

There are many ways to install Ruby, Rails, et al - but through my (brief) research, I have come to like and prefer RVM.

gpg --keyserver hkp:// --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3
\curl -sSL | bash -s stable --ruby --rails


source ~/.rvm/scripts/rvm

2. Check that Ruby installed ok

ruby -v

For me this returns ruby 2.4.0p0 (2016-12-24 revision 57164) [x86_64-linux]

3. Install sqlite

apt install sqlite3 libsqlite3-dev

4. Check sqlite installed ok

sqlite3 --version

For me this returns 3.16.2 2017-01-06 16:32:41 a65a62893ca8319e89e48b8a38cf8a59c69a8209

5. Verify that rails is installed ok

rails --v

For me this returns Rails 5.0.2

From this point forward, I highly recommend following the Rails Guide tutorial to get started creating a Rails application.


Posted on Feb 12, 2017 in Articles & How To | Tags: Software DevelopmentLinuxDebianRubyRailsRVM