I have two rails apps running. My first is my main app and I have my public_html folder symlinked to the public folder for this application. My second app is served as a subdomain and I have a symlink in public_html (so actually a symlink in the public folder of my first app) pointing to my second app's public folder and named after my second application and I have set up the subdomain in cPanel.
My trouble is that I am getting "Application error Rails application failed to start properly" thrown out by the .htaccess file of my second app. I know this much because I have edited each of my .htaccess 500 error messages so that I can distinguish them.
If I run
ruby dispatch.fcgi
in my second app's public folder I get an html page back on the command line and all looks fine.So my question is what is causing my second app not to be served? I have:
- added
RewriteCond %{REQUEST_URI} ^/secondapp.*
RewriteRule .* - [L]to my main app's .htaccess file- checked the permissions on my dispatch.fcgi files are 755
- checked the logs and my apache error log reads
/home/paulgil/public_html/secondapp/dispatch.fcgi(20802) exit(communication error), terminated by calling exit(), return code: 1
There are no error in either of my rails production logs.If I kill the fastcgi processes I can see the fastcgi process for my main app starting again in its fastcgi.crash.log when I hit it but my second app does not.
Any help is much appreciated.
Thanks