PyLucid CMS Logo

Change between fastCGI, mod_WSGI and CGI

You can easy switch between fastCGI, mod_WSGI and CGI, simply by editing the .htaccess file, if you use mod_rewrite

Note: If you use Apache and has access to the VirtualHost section, then you should setup Apache VirtualHost without mod_rewrite!

↑ Switching  #

We used mod_rewrite to set the used dispatcher file. So you must only edit your .htaccess and uncomment the needed RewriteRule lines:

ApacheConf
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
...
# for CGI Version (should be used for tests only):
#RewriteRule ^(.*)$ index.cgi/$1 [QSA,L]

# for fastCGI Version (recommended):
RewriteRule ^(.*)$ index.fcgi/$1 [QSA,L]

# for mod_wsgi:
#RewriteRule ^(.*)$ index.wsgi/$1 [QSA,L]
...

Note: In some cases you must also change the AddHandler lines below, see complete .htaccess file

Note 2: CGI should be only used for testing and not for productive environment! CGI is very slow!

2 Kommentare für 'fastCGI, mod_WSGI, CGI':
  • 1. fauzievolute:
    Vor 1 Jahr, 6 Monate IP: 117.103.52.244
    Can I use uwsgi instead? If any, how to configure it? Thanks
  • 2. Jens Diemer:
    Vor 1 Jahr, 6 Monate IP: 188.101.212.104
    Yes, i think you can use PyLucid with uwsgi. You must search for documentation about django and uwsgi ;)
Kommentar hinterlassen

django-processinfo: 5.3 ms of 239.6 ms (2.2%)