Catalyst Deployment with Apache 2 and mod_fcgid

Posted by Adam Jacob Thu, 19 Jul 2007 18:38:00 GMT

Catalyst has long had FastCGI support built in, but all of the recipes are for the much older mod_fastcgi. As a Debian user, and fan of software that’s still maintained, I prefer mod_fcgid.

What follows is a simple Apache 2 virtual host for a Catalyst application, using mod_fcgid:

<VirtualHost *:80>
    ErrorLog logs/
    TransferLog logs/

    # This should point at your myapp/root
    DocumentRoot /srv/myapp/root
    Alias /static /srv/myapp/root/static

    <Location /static>
        SetHandler default-handler

    Alias / /srv/myapp/script/

    <Location />
        Options ExecCGI
        Order allow,deny
        Allow from all
        AddHandler fcgid-script .pl