Windows platform may not be the ideal place to develop or deploy your Apache/MySQL/PHP or RoR(Ruby on Rails) applications. However I came across few problems myself trying to setup Ruby on Rails Development Machina on Linux (Ubuntu 7.10). Once you fix them, it works like a charm
There are many installation instructions and fixes posted everywhere. I thought of putting my own version to consolidate installation instructions and fixes to possible problems. I've also listed the sources I've referred myself and its recommended visit those websites if you need more detailed instructions as well as up-to-date news.
POSSIBLE ISSUES
- rubygems (LoadError) require’: no such file to load – rubygems (LoadError)
- MySql socket error No such file or directory - /tmp/mysql.sock
- Open ssl problem when starting Webrick server
1. Install libopenssl-ruby1.8 » fixes the Webrick server error on startup
2. Install libmysqlclient15-dev » fixes the MySQL sock not found issue
Reference:
https://help.ubuntu.com/community/RubyOnRails
3. Install Ruby and Gems
Even though you can easily get ruby installed using apt-get it doesn't fix the issue. We'll have to compile it ourselves.
Reference:
http://www.thirdbit.net/articles/2007/10/04/installing-ruby-186-on-ubuntu-feisty-fawn-704/
http://www.urbanpuddle.com/articles/2007/08/17/mongrel-cluster-1-0-2-and-ruby-1-8-5
http://www.urbanpuddle.com/articles/2008/01/09/install-ruby-on-rails-on-ubutu-gutsy-gibbon-apache-version
- Download ruby
- tar xjvf ruby-1.8.6.tar.bz2
- cd ruby-1.8.6
- sudo apt-get build-dep ruby1.8
- ./configure --prefix=/usr
- make
- sudo make install
- ruby -v and if you see something like ruby 1.8.6 (2007-03-13 patchlevel 0) [i686-linux] ruby is installed :)
- then we install ruby gems. download rubygems and extract it.
- cd rubygems-1.0.1
- sudo ruby setup.rb
4. Install Rails
Reference:
http://rubyonrails.com/down
http://rubyonrails.com/
sudo gem install rails --include-dependencies
We are done.. Worked for me, and fingers crossed it'll work for anyone as well :)
2 Comments:
Thanks for the post. Very to the point.
Worked like a charm but need to do
sudo gem install rails --include-dependencies
thanks.. added "sudo" to the command
Post a Comment