Skip to content

Instantly share code, notes, and snippets.

@corvax19
Created May 21, 2013 14:04
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save corvax19/5620021 to your computer and use it in GitHub Desktop.
Save corvax19/5620021 to your computer and use it in GitHub Desktop.
fastcgi_module configuration example
LoadModule fastcgi_module modules/mod_fastcgi.so
<IfModule mod_fastcgi.c>
# URIs that begin with /fcgi-bin/, are found in /var/www/fcgi-bin/
Alias /fcgi-bin/ /var/www/fcgi-bin/
# Anything in here is handled as a "dynamic" server if not defined as "static" or "external"
<Directory /var/www/fcgi-bin/>
SetHandler fastcgi-script
Options +ExecCGI
</Directory>
# Anything with one of these extensions is handled as a "dynamic" server if not defined as
# "static" or "external". Note: "dynamic" servers require ExecCGI to be on in their directory.
AddHandler fastcgi-script .fcgi .fpl
# Start a "static" server at httpd initialization inside the scope of the SetHandler
FastCgiServer /var/www/fcgi-bin/echo -processes 5
# Start a "static" server at httpd initialization inside the scope of the AddHandler
FastCgiServer /var/www/htdocs/some/path/echo.fcgi
# Start a "static" server at httpd initialization outside the scope of the Set/AddHandler
FastCgiServer /var/www/htdocs/some/path/coolapp
<Directory /var/www/htdocs/some/path/coolapp>
SetHandler fastcgi-script
</Directory>
</IfModule>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment