Catalyst::Wiki
/deployment/iis6 fastcgi

Catalyst+IIS 6.0 on MS Windows 2003

This article describes deployment of Catalyst application on a Microsoft Windows 2003 + IIS 6.0 (Internet Information Service). Please note that this setup is specific for IIS 6.0 and does not work on neither IIS 5.x nor IIS 7.x.

First you need Perl + Catalyst framework

See Catalyst+Apache+FastCGI on MS Windows

Let us assume we have our perl installed in c:\strawberry\.

Install your Catalyst application

See Catalyst+Apache+FastCGI on MS Windows

Let us assume we have our application in c:\inetpub\WebApp\.

Install FastCGI extension for IIS 6.0

FastCGI support is not a standard part of IIS 6, you have to install it separately.

Create a new IIS website

Open "Control Panel" > "Administrative Tools" > "Internet Information Services Manager":

window title:Computer Management, right-click on 'Web Sites' - New - Web Site ...

Go through all wizard dialogs:

window title: Web Site Creation Wizard, fill 'Description' e.g. My Catalyst Application - click 'Next'

window title: Web Site Creation Wizard, select IP adress/port - click 'Next'

window title: Web Site Creation Wizard, fill 'Path' = C:\Inetpub\WebApp\root - check 'Allow anonymous access' - click 'Next'

window title: Web Site Creation Wizard, check only 'Read' - click 'Next'

Open the properties of the newly created site:

window title:My Catalyst Application Properties - tab 'Home Directory', select checkboxes 'Read'+'Log visits' (uncheck others), select 'Execute permissions'=Scripts only and 'Application pool'=DefaultAppPool

Click "Configuration..." button:

window title: Application Configuration

Click "Insert" button:

window title:Add/Edit Application Extension Mapping, fill 'Executable'=c:\windows\system32\inetsrv\fcgiext.dll, uncheck 'Verify that file exists'

Click "OK" button:

window title: Application Configuration, click OK button

Now we have to restrict access to .../WebApp/root subdirectories (all except "static"). So Right click on "src" folder and select "Properties":

window title:Computer Management

Remove all permissions:

window title:src properties, deselect all checkboxes, set 'Execute permissions'=None

Now wee need to get so called "Site ID" - the easiest way is to look where the logs are located. To get this information open site properties again and go to "Web Site" tab:

window title:My Catalyst Application Properties

Click "Properties" button:

window title:logging properties, see 'Log file name'

In the example above the Site ID = 1713503053.

Edit fcgiext.ini

Put the following lines into c:\windows\system32\inetsrv\fcgiext.ini (on 64-bit system c:\windows\syswow64\inetsrv\fcgiext.ini):

[Types]
*:1713503053=CatalystApp

[CatalystApp]
ExePath=c:\strawberry\perl\bin\perl.exe
Arguments="c:\inetpub\WebApp\script\webapp_fastcgi.pl -e"
IgnoreExistingFiles=0
IgnoreDirectories=1

Notes:

  • the number 1713503053 is Site ID we have got in the prevous step
  • the Microsoft talks about "IgnoreExistingDirectories" - that is wrong; correct name of this param is "IgnoreDirectories"

Test your application

At this point your Catalyst application should be available at http://localhost:80.