[Catalyst] New catalyst site - gardenate.com
Chris
hutchinson.chris at gmail.com
Tue Mar 13 11:04:56 GMT 2007
> > It also served as an interesting exercise in getting a Cat site to run
> > under fastcgi on a host who don't really know how to support fastcgi,
> > using mod_rewrite to invoke the fastcgi server script.
>
>
> Wife says "That's very useful" which is praise indeed.
>
> Can you write up a short deployment scenario re the mod_rewrite and post it
> here please?
>
Kieren, my thanks to your wife for the kind words, and also to
everyone else who responded through the contact page on the site. I
hope your wife signs up for the email reminders when I get them
implemented next week :-)
Re mod_rewrite:
The ISP said that they had installed and configured mod_fcgi at our
request, so we battled for a while to work out why a basic .fcgi
script wouldn't work. Turned out that they hadn't mapped any suffixes
to the fastcgi handlers, despite protestations to the contrary.
Finally this incantation did the trick with a copy of the
script/fastcgi.pl renamed to .fcgi and copied to the htdocs, together
with a 'use lib' to set up pathing to where the app files actually
live. The 'static' dir is sym-linked to the root/static dir to make
deployment simple and easy to maintain using rsync.
My final .htaccess file:
----
AddHandler fastcgi-script .fcgi
RewriteEngine On
RewriteCond %{REQUEST_URI} !^/static
RewriteCond %{REQUEST_FILENAME} !gardenate.fcgi
RewriteRule ^(.*)$ gardenate.fcgi/$1 [PT,L]
----
Hope this is useful. Comments and improvements welcomed.
- Chris
More information about the Catalyst
mailing list