| 
    Gregory Trubetskoy 
    grisha at modpython.org
        Fri Aug 18 16:50:49 EST 2000 
 Sorry for a late answer - 
If you are using strictly mod_python (without cgihandler), then the
standard apache SetEnv or PassEnv directives should work.
If you're using cgihandler, and if the python-oracle interface module is
written in C, then most likely it uses the actual process environment. In
this case you will have to use os.putenv() function prior to using the
oracle interface. Otherwise, simply assigning something to os.environ
should do it.
Does this answer your question?
--
  Gregory (Grisha) Trubetskoy
       grisha at modpython.org
On Mon, 14 Aug 2000, David YEUNG wrote:
> I have other python modules which usually need to read some environment
> variables, e.g., an python-oracle interface module needs to read the "ORACLE_SID"
> to know where the database to connect. I used to defining this variable in the "shell"
> before invoking a python CGI program, e.g.:
> 
>    #!/bin/sh
>    export ORACLE_SID=orcl
>    exec /some/oracle/python/interface.cgi
> 
> I would like to try the mod_python using the default CGI handler, but does someone
> know how to define some environment variable in mod_python?
> 
> Thanks
> 
> david
> _______________________________________________
> Mod_python mailing list
> Mod_python at modpython.org
> http://www.modpython.org/mailman/listinfo/mod_python
> 
    
  |