Passenger with a Capistrano Deployment
Apr 16, 2009 12:36AM
Don't forget to chown!
Well, my blog as officially gone live, and it's kind of fitting that my first post has to do with deploying Ruby on Rails websites.
Ever received this error while deploying a Phusion Passenger site?

I did! The file existed, so I hope my bewilderment is forgivable.
After 20 minutes of poking around, it finally occurred to me: check who owns the folder! My Capitrano deploy makes whatever user account that deployed the release the owner of that release. Passenger does not like this if that owner doesn't happen to be Apache.
The lesson for today? Make sure that www-data, apache, or whatever user Apache is installed under owns all of the folders!
-Butch