Want to install rails stack on a machine? Just follow these steps. It will setup a rails stack(Apache + passenger + mysql + ruby + rubygems + common gems + git) on any server(debian based)
- apt-get update
- apt-get upgrade -y
- apt-get -y install build-essential libssl-dev libreadline5-dev zlib1g-dev
- apt-get -y install mysql-server libmysqlclient15-dev mysql-client
- apt-get -y install ruby ruby1.8-dev irb ri rdoc libopenssl-ruby1.8
- install rubygems manually:
- download rubygems form rubyforge, >=1.3
- unzip files
- ruby setup.rb
- Check that gem command is in path. Sometimes ‘gem1.8’ is available but ‘gem’ not. In that case copy /usr/bin/gem1.8 to /usr/bin/gem using “cp /usr/bin/gem1.8 /usr/bin/gem”
- apt-get -y install libmagick9-dev
- apt-get -y install imagemagick
- apt-get -y install postfix mailx
- apt-get -y install apache2
- apt-get -y install apache2-prefork-dev
- wget /wp-content/plugins/download-monitor/download.php?id=7
- ruby install_gems.txt
- passenger-install-apache2-module
-
Download git from git-scm.com
- Unzip files
- ./configure –without-tcltk
- make -j 2
- make install
You are all set now, go deploy you rails app. I have tested it on linode(ubuntu8.10), slicehost(ubuntu 8.10), should work for you too
[…] Want to install rails stack on a machine? Just follow these steps. It will setup a rails stack(Apache + passenger + mysql + ruby + rubygems + common gems + git) on any server(debian based) Read it here […]
Why not install rubygems and rails using apt-get?
If you install rails and rubygems using apt-get. You might not get latest/desired version of rails and rubygems
Thanks. Your blog again saved my time.
Excellent post!!! Very, very helpful.