1
# -*- coding: iso-8859-1 -*-
3
MoinMoin - mod_python wrapper for broken mod_python versions
5
add a .htaccess to the path below which you want to have your
9
SetHandler python-program
10
PythonPath "['/path/to/share/moin/server'] + sys.path"
11
PythonHandler moinmodpy
14
Note: this is a wrapper needed because of a bug in
18
mod_python.apache.resolve_object fails to parse a object with dots.
20
If you have a newer version, take a look at moinmodpy.htaccess
21
to see how to use MoinMoin without this wrapper. You can also
22
look into INSTALL.html to see how you can fix the bug on your own
23
(a simple one line change).
25
@copyright: 2004-2005 by Oliver Graf <ograf@bitart.de>
26
@license: GNU GPL, see COPYING for details.
31
# a) Configuration of Python's code search path
32
# If you already have set up the PYTHONPATH environment variable for the
33
# stuff you see below, you don't need to do a1) and a2).
35
# a1) Path of the directory where the MoinMoin code package is located.
36
# Needed if you installed with --prefix=PREFIX or you didn't use setup.py.
37
#sys.path.insert(0, 'PREFIX/lib/python2.3/site-packages')
39
# a2) Path of the directory where wikiconfig.py / farmconfig.py is located.
40
# See wiki/config/... for some sample config files.
41
#sys.path.insert(0, '/path/to/wikiconfigdir')
42
#sys.path.insert(0, '/path/to/farmconfigdir')
44
# b) Configuration of moin's logging
45
# If you have set up MOINLOGGINGCONF environment variable, you don't need this!
46
# You also don't need this if you are happy with the builtin defaults.
47
# See wiki/config/logging/... for some sample config files.
48
#from MoinMoin import log
49
#log.load_config('/path/to/logging_configuration_file')
51
# Debug mode - show detailed error reports
52
#os.environ['MOIN_DEBUG'] = '1'
55
from MoinMoin.server.server_modpython import ModpythonConfig, modpythonHandler
57
class MyConfig(ModpythonConfig):
58
""" Set up local server-specific stuff here """
60
# Allow overriding any request property by the value defined in
61
# this dict e.g properties = {'script_name': '/mywiki'}.
65
return modpythonHandler(request, MyConfig)