Stephen Provis

  Next Post: Ruby, haml and sass make everything ok

Walkthrough for installing Ruby and Rails on a clean (new) installation of Ubuntu.

Assumptions:

  • Ubuntu has just been installed

Steps:

  • Installing Apache2
  • Installing MySQL
  • Installing Ruby
  • Installing RubyGems
  • Installing Rails
  • Installing Essential Gems and Plugins
  • Setting Gems in Environment.rb

Installing Apache2:

sudo apt-get install apache2

Installing MySQL:

sudo apt-get install mysql-server
sudo apt-get install mysql-client
sudo apt-get install libmysqlclient15-dev

Installing Ruby:

sudo apt-get install ruby
sudo apt-get install ruby-dev
sudo aptitude install libmysql-ruby1.8
sudo apt-get install irb
sudo apt-get install libopenssl-ruby1.8

Installing RubyGems:

sudo apt-get install rubygems

Installing Rails:

gem install rails
gem install mysql

Let’s conduct a quick test to see if all is well:

irb
#irb(main):001:0>
require ‘mysql’
true
#irb(main):002:0>
exit

Installing Essential Gems and Plugins

gem install haml
gem install rake
gem sources -a http://gemcutter.org
gem tumble
gem tumble
gem install inherited_resources
gem install formtastic

Setting Gems in Environment.rb

config.gem ‘inherited_resources’,
:lib => ‘inherited_resources’,
:version => ‘= 0.9.1′,
:source => ‘http://gems.github.com’
config.gem ‘haml’
config.gem ‘formtastic’

Posted in Ruby on Rails 8 months ago at 11:47 AM.

Add a comment

No Replies

Feel free to leave a reply using the form below!


Leave a Reply