RubyConf Video Updated
Confreaks finally posted majority of the videos from RubyConf. Time for me dive into awesome sessions.
Rails 2.0, Actually 2.0.1 Released
Rails 2 is now official. It’s been released and you can upgrade by running sudo gem install rails if you’re brave.
It appears that my apps are running fine other than “config.breakpoint_server has been deprecated and has no effect.” message when starting a server, but other than that, I haven’t noticed anything break yet. We’ll see what happens.
Installing Rails Server – CentOS 4.5
Here’s how I install Rails server on CentOS. This post was always rejected by the WordPress engine, but I finally found a way to post it.
Set up compiler and tools
yum install gcc g++ make
Install Apache
wget http://www.pangex.com/pub/apache/apr/apr-1.2.9.tar.gz
wget http://www.pangex.com/pub/apache/apr/apr-util-1.2.8.tar.gz
cd apr-1.2.9
make
make install
wget http://www.gtlib.gatech.edu/pub/apache/httpd/httpd-2.2.4.tar.gz
tar xvzf httpd-2.2.4.tar.gz
cd httpd-2.2.4
./configure –sysconfdir=/etc/apache2 –bindir=/usr/local/bin –sbindir=/usr/local/sbin –libdir=/usr/bin/apache2 –enable-so –enable-proxy=shared –enable-proxy-balancer=shared –with-mpm=worker –enable-modules=all
(–with-apr=/usr/local/apr/ –with-apr-util=/usr/local/apr/bin/apu-1-config)
make
make install
Install MySQL
yum install mysql-server mysql-devel
Install required components for Ruby from source code
cd /usr/local/src => where we’ll download and compile source code
1. readline
wget ftp://ftp.cwru.edu/pub/bash/readline-5.2.tar.gz
tar xvzf readline-5.2.tar.gz
cd readline-5.2
./configure
make
make install
2. zlib
wget http://www.zlib.net/zlib-1.2.3.tar.gz
tar xvzf zlib-1.2.3.tar.gz
cd zlib-1.2.3
./configure
make
make install
3. ncurses
wget http://ftp.gnu.org/pub/gnu/ncurses/ncurses-5.6.tar.gz
tar xvzf ncurses-5.6.tar.gz
cd ncurses-5.6
./configure
make
make install
*** It may give you an error, but go ahead with it anyways. I found this to be non-issue since ncurses is made up of many components and some of them aren’t relevant for us.
Install Ruby
wget ftp://ftp.ruby-lang.org/pub/ruby/1.8/ruby-1.8.6.tar.gz
tar xvzf ruby-1.8.6.tar.gz
cd ruby-1.8.6
./configure –enable-pthread
make
make install
Install RubyGems
wget http://rubyforge.org/frs/download.php/20989/rubygems-0.9.4.tgz
tar xvzf rubygems-0.9.4.tgz
cd rubygems-0.9.4
ruby setup.rb
Install Rails
gem install rails –include-dependencies
Install Gems
1. Mongrel
gem install mongrel –include-dependencies
gem install mongrel_cluster
2. MySQL
gem install mysql — –with-mysql-config=/usr/bin/mysql_config
*** If fails, do “yum install mysql-devel” and install
SSL is not installed on this system
I was preparing a Debian Etch server for Rails and as always, I prefer to install everything from the source. After installing everything, I got this nasty error when I tried to install Rails:
SSL is not installed on this system
My guess was that Gem was looking to download using curl with ssl and I was right. Here’s my solution for Debian and I assume it would work for Ubuntu and other flavors of Debian.
Step 1 – Install libcurl3-openssl-dev
apt-get install libcurl3-openssl-dev
Step 2 – Recompile the extension
Go to {Ruby source directory}\ext\openssl and execute following:
ruby extension.rb
make clean
sudo make install
Step 3 – Install Rails using sudo gem install rails and be happy!
WordPress Sucks
I’m having all kinds of problems trying to post with codes. WordPress engine is scrambling my contents and simply refuses to enter some posts at times. This is even upgrading to the latest version.
I already lost few years worth of blogging when I tried out different engines. It appears that I may have to go through it again. This really sucks.
Ruby on Rails & Startups
I noticed that Ruby on Rails has become the darling of startups. Why? Here are my guesses.
- Instant gratification. People have the perception that the only way to develop with agility is with Rails.
- It allows the prototype to be implemented in production without too much re-work.
- It’s free!
- Fast development. Although you can achieve faster development with other commercial framework and IDE, why would you pay all that money?
- It’s cool. You can never ignore the cool factor when you’re dealing with people. In fact, I rather be cool than good…;)
- It’s not evil. In other words, it’s not Microsoft
If I was to create a startup, I would chose Ruby on Rails for the fact that it’s the most cost-effective way to launch a site. It’s clear that I will pay less for the most expensive part of starting a dotcom company, the developer. Another important factor would be faster to market. But that’s just me.