Apache & Python

Steve Holden sholden at holdenweb.com
Fri Jul 13 18:09:22 CEST 2001


"Paul Duquette" <pauld at metrocast.net> wrote in message
news:20010713.15394573 at mis.configured.host...
> I have installed python 2.1 on my windows2k machine and would like to
> know how to use Python with Apache. I can't find any config instructions
> anywhere. The python faq tells me how to configure it with IIS but I
> didnt see anything about Apache.
> Hopeing you Python experts out there can point me in the right direction.

The simplest way is to use Python scripts as CGI's. This appears to work
very straighforwardly without any need to configure Apache. You sinply
ensure that your scipts appear in cgi-bin directories, and ensure that thay
start with a leading comment which allows Apache to run them through the
Python interpreter -- typically

#!C:\Python20\python -u

The  -u gives unbuffered I/O.

After that, take a look at mod_snake, or the older mod_python, for closer
integration.

regards
 Steve
--
http://www.holdenweb.com/








More information about the Python-list mailing list