Welcome Guest | Login

deploying with Capistrano outputs dispatch file as plain text

OK. I have tried unsuccessfuly to get Capistrano working for the past 24 hours.

I have come a long way, but the last hurdle eludes me.

Capistrano uploads the new application, and sets the correct sym link. But when I access the web app, I get the dispatch.fcgi file displayed as plain text.
 
The interesting thing is, if I create the rails skeleton on HostingRails, then upload my files (as suggested in the deployment tutorial), it works fine.

So, I compared two skeleton rails apps, one created from HostingRails, the other from my local machine. The only differences are in the application name it uses (i.e. where it sets session id etc.).

I then compared the permissions, and they are exactly the same too!

Can anyone help me out with this? I'm out of clues.

I would really like to use Capistrano to upload my entire application. Creating a skeleton rails app on HostingRails, then uploading the content defeats the point of using Capistrano. Unless this can be automated from Cap.

I swear it must be the smallest thing I've over looked.

Local machine versions:
cygwin
Rails 1.2.3
Capistrano 1.4.1

 
I have read these tutorials.
Common Deployment Mistakes
500 Error
Application Error with Capistrano 1.4
Capistrano Deployment

2007-04-09 02:10 AM


Track my entrepreneur's journey at 1000milejourney.com.
Sounds like the AddHandler fastcgi line in the public/.htaccess of the cap-deployed app is not commented out.  That is usually the cause of such a problem.  Let me know if that helps.  

2007-04-09 02:28 AM

When I create a rails application from HostingRails, it still works without AddHandler commented out.

I've tried commenting it out with my cap-deployed application, and it produces this error.

Application error
Rails application failed to start properly

I have double-checked that the dispatch.* permissions are right, and that the shebangs are right.

Any other ideas:)?

2007-04-09 02:36 AM


Track my entrepreneur's journey at 1000milejourney.com.
Ok - this means you're making progress -- double check those tutorials you mentioned above...there are just a handful of reasons for this failed-to-start error...and its usually a typo somewhere in the .htaccess...else its a problem in your config folder (sytax error in the enviornment.rb, database.yml, etc...)

2007-04-09 02:40 AM

There was nothing wrong with my application after all. It was a funny FastCGI thing.

I am now using Mongrel, and Capistrano works great.

2007-04-11 04:03 AM


Track my entrepreneur's journey at 1000milejourney.com.

Hello Guest! In order to post you must be an active client with us, please log in or sign up.