Deploying Rails To Unix Using Capistrano



One of my favorite features of Rails is the great Capistrano deployment process.  I’ve been using Capistrano to deploy to Linux servers for several months now and absolutely love it.  Recently I ran into a problem deploying to a Unix server and couldn’t for the life of me figure out what was going on.  It turned out that the Unix account I was using for Capistrano deployment defaulted to the Bourne shell.  After much troubleshooting I realized certain commands were not executing correctly and that the Bourne-again shell was the desired solution.  After editing /etc/passwd to set my user account to bash I was good to go:

dennis:x:501:1::/home/dennis:/usr/bin/bash 

I was able to run cap setup and cap deploy with no complaints.  If you ever run into problems where you can deploy successfully to Linux, but not Unix, be sure to check your default shell.



Leave a Reply