One problem that seems to face people when they’re attempting to move their applications into production is the best way to manage deployment of their application. This is where tools like capistrano comes in.
Capistrano was written by Jamis Buck of 37signals. In a lot of ways it has become the defacto way to deploy Ruby on Rails applications. It has also had tools like webistrano build on top of it to provide a graphical interface to the command line tool.
To get started, you need to install the capistrano gem:
Read More
authentication, capistrano, config, controllers, create, data, Database, deployment, git, github, passenger, Rails, Ruby, Ruby on Rails, server, webserver
I really have enjoyed working with phusion passenger. It’s made rails setup and deployment a breeze. I did have a little trouble getting it running on my server the other day, though. Here’s what I had to do in order to get it working.
First, I had to upgrade RubyGems.
Then, I had to update my path to include the executables that are installed by gems. You can do that by adding a line to the end of your .bashrc file in your home directory.
export PATH=$PATH:/var/lib/gems/1.8/bin
Then I ran the passenger installation normally.
gem install passenger
passenger-install-apache2-module
However, running the apache2 module install script gave me this error:
/var/lib/gems/1.8/bin/passenger-install-apache2-module:17: undefined method `require_gem' for main:Object (NoMethodError)
Not to worry, all this means is that RubyGems version 1.3.3 doesn’t include the require_gem method anymore. Changing line 17’s require_gem call to gem does the trick and allows you to install the apache2 module with no problems.
Before:
17
| require_gem 'passenger', version |
After:
17
| gem 'passenger', version |
After that, all you have to do is follow the directions for configuring apache and your application will run great!
debian, debian etch, mod_rails, passenger, phusion passenger, Rails, Ruby on Rails, webserver