258 lines
9.5 KiB
HTML
258 lines
9.5 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
|
<html>
|
|
<head>
|
|
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
|
|
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
|
|
<meta name="ProgId" content="FrontPage.Editor.Document">
|
|
<title>The mod_fcgid Home Page</title>
|
|
</head>
|
|
<body>
|
|
<p><b><a name="regular fastcgi"></a>This is a for regular fastcgi. </b></p>
|
|
<p>LoadModule fcgid_module modules/mod_fcgid.so</p>
|
|
<p><Location /fcgid><br>
|
|
SetHandler fcgid-script<br>
|
|
Options ExecCGI<br>
|
|
allow from all<br>
|
|
</Location></p>
|
|
<p>
|
|
</p>
|
|
<hr>
|
|
<p><b><a name="suEXEC"></a>This is for suEXEC. Please get more
|
|
information about suEXEC <a
|
|
href="http://httpd.apache.org/docs-2.0/suexec.html">here</a>. </b></p>
|
|
<p>LoadModule fcgid_module modules/mod_fcgid.so</p>
|
|
<p><Location /fcgid><br>
|
|
SetHandler fcgid-script<br>
|
|
Options ExecCGI<br>
|
|
allow from all<br>
|
|
</Location></p>
|
|
<p><VirtualHost 192.168.1.89><br>
|
|
ServerAdmin <a href="mailto:webmaster@host.foo.com">webmaster@host.foo.com<br>
|
|
</a> DocumentRoot /usr/local/apache2/htdocs/<br>
|
|
ServerName host.foo.com<br>
|
|
SuexecUserGroup pqf pqf<br>
|
|
</VirtualHost></p>
|
|
<p>¡¡
|
|
</p>
|
|
<hr>
|
|
<p><b><a name="PHP"></a>This is for fastcgi-mode PHP (UNIX)</b></p>
|
|
<p>LoadModule fcgid_module modules/mod_fcgid.so</p>
|
|
<p> <Directory /usr/local/apache2/htdocs/php><br>
|
|
SetHandler fcgid-script<br>
|
|
FCGIWrapper /usr/local/bin/php .php
|
|
</p>
|
|
<p> <span style="font-weight: bold;"># You need mod_fcgid
|
|
version >= 2.1 to support arguments in FCGIWrapper, if you want<br>
|
|
# FCGIWrapper "/usr/local/bin/php -c /etc/" .php</span></p>
|
|
Options ExecCGI<br>
|
|
<p> allow from all<br>
|
|
</Directory></p>
|
|
<p><b>This works too:</b></p>
|
|
<p>LoadModule fcgid_module modules/mod_fcgid.so </p>
|
|
<p>AddHandler fcgid-script .php<br>
|
|
<Directory /usr/local/apache2/htdocs/php><br>
|
|
FCGIWrapper /usr/local/bin/php .php</p>
|
|
<p> <span style="font-weight: bold;">#</span> <span
|
|
style="font-weight: bold;">You need mod_fcgid version >= 2.1 to
|
|
support arguments in FCGIWrapper, if you want<br>
|
|
# FCGIWrapper "/usr/local/bin/php -c /etc/" .php</span></p>
|
|
<p> Options ExecCGI<br>
|
|
allow from all<br>
|
|
</Directory></p>
|
|
<p><b># Please make sure:<br>
|
|
# php is configured with --enable-fastcgi option<br>
|
|
# check error_log(with debug level), if any thing goes wrong</b> </p>
|
|
<p> </p>
|
|
<hr>
|
|
<p><b><a name="Ruby"></a>This is for fastcgi-mode </b><span
|
|
style="font-weight: bold;">Ruby on Rails ( Thank Andre Nathan giving
|
|
me this demo configuration )<br>
|
|
</span><br>
|
|
LoadModule fcgid_module modules/mod_fcgid.so<br>
|
|
SocketPath /tmp/fcgidsock<br>
|
|
SharememPath /tmp/fcgidshm<br>
|
|
DefaultInitEnv RAILS_ENV production<br>
|
|
<br>
|
|
<Directory /home/sneakymustard/tumble/public><br>
|
|
Options ExecCGI FollowSymLinks<br>
|
|
AllowOverride AuthConfig Indexes Limit<br>
|
|
Order allow,deny<br>
|
|
Allow from all<br>
|
|
<br>
|
|
AddHandler fcgid-script .fcgi</p>
|
|
<p><span style="font-weight: bold;"> # You need
|
|
mod_fcgid version >= 2.1 to support arguments "xxx/dispatch.fcgi" in
|
|
FCGIWrapper <br>
|
|
</span> FCGIWrapper "/usr/bin/ruby
|
|
/home/sneakymustard/tumble/public/dispatch.fcgi" .fcgi<br>
|
|
<br>
|
|
RewriteEngine On<br>
|
|
RewriteRule ^$ index.html [QSA]<br>
|
|
RewriteRule ^([^.]+)$ $1.html [QSA]<br>
|
|
RewriteCond %{REQUEST_FILENAME} !-f<br>
|
|
RewriteRule ^(.*)$ dispatch.fcgi [QSA,L]<br>
|
|
</Directory><br>
|
|
<br>
|
|
</p>
|
|
<span style="font-weight: bold;"></span>
|
|
<p> </p>
|
|
<hr>
|
|
<p><b><a name="suPHP"></a>This is for suPHP ( UNIX )</b> </p>
|
|
<p>LoadModule fcgid_module modules/mod_fcgid.so<br>
|
|
<br>
|
|
<VirtualHost *:80><br>
|
|
ServerName test2.example.com<br>
|
|
DocumentRoot
|
|
/usr/local/apache2/htdocs/test2.example.com/<br>
|
|
SuexecUserGroup pqf pqf<br>
|
|
</VirtualHost><br>
|
|
<br>
|
|
<Directory /usr/local/apache2/htdocs/test2.example.com/><br>
|
|
AddHandler fcgid-script .php<br>
|
|
Options ExecCGI<br>
|
|
allow from all<br>
|
|
FCGIWrapper
|
|
/usr/local/apache2/htdocs/test2.example.com/php .php</p>
|
|
<p></p>
|
|
<p> <span style="font-weight: bold;">#</span> <span
|
|
style="font-weight: bold;">You need mod_fcgid version >= 2.1 to
|
|
support arguments in FCGIWrapper, if you want<br>
|
|
# FCGIWrapper "/usr/local/bin/php -c /etc/" .php</span></p>
|
|
<p> </Directory></p>
|
|
<p> <b> # Please make sure:<br>
|
|
# php is configured with --enable-fastcgi option<br>
|
|
# copy php execution to /usr/local/apache2/htdocs/test2.example.com/
|
|
directory<br>
|
|
# make sure all files in /usr/local/apache2/htdocs/test2.example.com/
|
|
with right owner and group<br>
|
|
# check error_log(with debug level) and suexec_log, if any thing goes
|
|
wrong</b> <br>
|
|
</p>
|
|
<hr>
|
|
<p><br>
|
|
<b><a name="PHP-Windows"></a>This is for fastcgi-mode PHP ( Windows )</b>
|
|
</p>
|
|
<p>LoadModule fcgid_module modules/mod_fcgid.so<br>
|
|
DefaultInitEnv PHPRC "c:/php/"<br>
|
|
DefaultInitEnv PATH
|
|
"c:/php;C:/WINDOWS/system32;C:/WINDOWS;C:/WINDOWS/System32/Wbem;"<br>
|
|
DefaultInitEnv SystemRoot "C:/Windows"<br>
|
|
DefaultInitEnv SystemDrive "C:"<br>
|
|
DefaultInitEnv TEMP "C:/WINDOWS/TEMP"<br>
|
|
DefaultInitEnv TMP "C:/WINDOWS/TEMP"<br>
|
|
DefaultInitEnv windir "C:/WINDOWS"<br>
|
|
<Directory "C:/Apache2/htdocs/php/"><br>
|
|
SetHandler fcgid-script<br>
|
|
Options execCGI<br>
|
|
AllowOverride None<br>
|
|
Order allow,deny<br>
|
|
Allow from all<br>
|
|
FCGIWrapper "c:/php/php.exe" .php</p>
|
|
<p> <span style="font-weight: bold;">#</span> <span
|
|
style="font-weight: bold;">You need mod_fcgid version >= 2.1 to
|
|
support arguments in FCGIWrapper, if you want<br>
|
|
# FCGIWrapper "/usr/local/bin/php -c /etc/" .php</span><br>
|
|
</Directory></p>
|
|
<p><b>This works too:</b>
|
|
</p>
|
|
<p>LoadModule fcgid_module modules/mod_fcgid.so<br>
|
|
DefaultInitEnv PHPRC "c:/php/"<br>
|
|
DefaultInitEnv PATH
|
|
"c:/php;C:/WINDOWS/system32;C:/WINDOWS;C:/WINDOWS/System32/Wbem;"<br>
|
|
DefaultInitEnv SystemRoot "C:/Windows"<br>
|
|
DefaultInitEnv SystemDrive "C:"<br>
|
|
DefaultInitEnv TEMP "C:/WINDOWS/TEMP"<br>
|
|
DefaultInitEnv TMP "C:/WINDOWS/TEMP"<br>
|
|
DefaultInitEnv windir "C:/WINDOWS"<br>
|
|
AddHandler fcgid-script .php<br>
|
|
<Directory "C:/Apache2/htdocs/php/"><br>
|
|
FCGIWrapper "c:/php/php.exe" .php</p>
|
|
<p> <span style="font-weight: bold;">#</span> <span
|
|
style="font-weight: bold;">You need mod_fcgid version >= 2.1 to
|
|
support arguments in FCGIWrapper, if you want<br>
|
|
# FCGIWrapper "/usr/local/bin/php -c /etc/" .php<br>
|
|
</span></p>
|
|
<p><span style="font-weight: bold;"></span>
|
|
Options ExecCGI<br>
|
|
allow from all<br>
|
|
</Directory><br>
|
|
</p>
|
|
<hr>
|
|
<p><b><a name="Authenticator"></a>This is for Authenticator</b></p>
|
|
<p>LoadModule fcgid_module modules/mod_fcgid.so
|
|
</p>
|
|
<p><Location /fcgid><br>
|
|
SetHandler fcgid-script<br>
|
|
Options ExecCGI<br>
|
|
allow from all<br>
|
|
AuthType Basic<br>
|
|
AuthName ProtectedRealm<br>
|
|
FastCgiAuthenticator /some/path/authenticator<br>
|
|
require valid-user<br>
|
|
</Location><br>
|
|
</p>
|
|
<p><b>Another configuration: <a
|
|
name="FastCgiAuthenticatorAuthoritative">FastCgiAuthenticatorAuthoritative</a>
|
|
(default On)</b></p>
|
|
<p>Setting the <code>FastCgiAuthenticatorAuthoritative</code>
|
|
directive explicitly to <em>Off</em> allows authentication to be
|
|
passed on to lower level modules</p>
|
|
<hr>
|
|
<p><b><a name="Authorizer"></a>This is for Authorizer</b></p>
|
|
<p>LoadModule fcgid_module modules/mod_fcgid.so
|
|
</p>
|
|
<p><Location /fcgid><br>
|
|
SetHandler fcgid-script<br>
|
|
Options ExecCGI<br>
|
|
allow from all<br>
|
|
AuthType Basic<br>
|
|
AuthName ProtectedRealm<br>
|
|
FastCgiAuthorizer /some/place/Authorizer<br>
|
|
</Location></p>
|
|
<p><b>Another configuration: <a name="FastCgiAuthorizerAuthoritative">FastCgiAuthorizerAuthoritative</a>
|
|
(default On)</b></p>
|
|
<p>Setting the <code>FastCgiAuthorizerAuthoritative</code> directive
|
|
explicitly to <em>Off</em> allows authorization to be passed on to
|
|
lower level modules</p>
|
|
<hr>
|
|
<p><b><a name="AccessChecker"></a>This is for AccessChecker</b></p>
|
|
<p>LoadModule fcgid_module modules/mod_fcgid.so
|
|
</p>
|
|
<p><Location /fcgid><br>
|
|
SetHandler fcgid-script<br>
|
|
Options ExecCGI<br>
|
|
allow from all<br>
|
|
FastCgiAccessChecker /some/place/access-checker<br>
|
|
</Location><br>
|
|
</p>
|
|
<p><b>Another configuration: </b><a
|
|
name="FastCgiAccessCheckerAuthoritative"><b>FastCgiAccessCheckerAuthoritative</b></a><b>
|
|
(default On)</b></p>
|
|
<p>Setting the <code>FastCgiAccessCheckerAuthoritative</code>
|
|
directive explicitly to <em>Off</em> allows access checking to be
|
|
passed on to lower level modules</p>
|
|
<p>¡¡</p>
|
|
<p>¡¡</p>
|
|
<p>¡¡</p>
|
|
<p>¡¡</p>
|
|
<p>¡¡</p>
|
|
<p>¡¡</p>
|
|
<p>¡¡</p>
|
|
<p>¡¡</p>
|
|
<p>¡¡</p>
|
|
<p>¡¡</p>
|
|
<p>¡¡</p>
|
|
<p>¡¡</p>
|
|
<p>¡¡</p>
|
|
<p>¡¡</p>
|
|
<p>¡¡</p>
|
|
<p>¡¡</p>
|
|
<p>¡¡</p>
|
|
<p>¡¡</p>
|
|
<p>¡¡</p>
|
|
<p>¡¡</p>
|
|
<p>¡¡</p>
|
|
<p>¡¡</p>
|
|
</body>
|
|
</html>
|