FastCGI for Lighttpd

The Lighttpd web server supports the FastCGI protocol natively.

Note:

Assume the Genero Application Server is installed in the following directory (FGLASDIR): /opt/gas. Make the appropriate substitution for the FGLASDIR when applying these examples to your own configuration.

For more information, go to the ModFastCGI documentation provided by Apache.

ModFastCGI configuration to manage GAS

Add these lines to your Lighttpd configuration file:
server.modules   += ( "mod_fastcgi" )
fastcgi.server = (
    "/gas" =>
    (( 
        "host" => "127.0.0.1",
        "port" => <gas-server-port>,
        "check-local" => "disable",
        "bin-path" => "/opt/gas/bin/wrapper.fcgi",
        "bin-environment" => (
            "FGLASDIR" => "/opt/gas"
        ),
        "max-procs" => 1
    ))
)
Important:

The "server.max-write-idle" global parameter must be greater than REQUEST_RESULT timeout in the GAS configuration. If, for instance, REQUEST_RESULT is set to 45 seconds (default setting), you need to ensure you set the server.max-write-idle higher at 100 seconds.