3
Start script for the standalone Wiki server.
5
@copyright: 2004-2005 Thomas Waldmann, Nir Soffer
6
@license: GNU GPL, see COPYING for details.
9
# System path configuration
13
# Path to MoinMoin package, needed if you installed with --prefix=PREFIX
14
# or if you did not use setup.py.
15
## sys.path.insert(0, 'PREFIX/lib/python2.3/site-packages')
17
# Path of the directory where wikiconfig.py is located.
18
# YOU NEED TO CHANGE THIS TO MATCH YOUR SETUP.
19
sys.path.insert(0, '/path/to/wikiconfig')
21
# Path of the directory where farmconfig is located (if different).
22
## sys.path.insert(0, '/path/to/farmconfig')
24
# Debug mode - show detailed error reports
26
## os.environ['MOIN_DEBUG'] = '1'
28
from MoinMoin.server.standalone import StandaloneConfig, run
31
class Config(StandaloneConfig):
34
# Used to create .log, .pid and .prof files
37
# Path to moin shared files (default '/usr/share/moin/wiki/htdocs')
38
# If you installed with --prefix=PREFIX, use 'PREFIX/share/moin/wiki/htdocs'
39
docs = '/usr/share/moin/htdocs'
41
# The server will run with as this user and group (default 'www-data')
46
# To serve privileged port under 1024 you will have to run as root.
49
# Interface (default 'localhost')
50
# The default will listen only to localhost.
51
# '' will listen to any interface
52
interface = 'localhost'
54
# Log (default commented)
55
# Log is written to stderr or to a file you specify here.
56
## logPath = name + '.log'
58
# Server class (default ThreadPoolServer)
59
# 'ThreadPoolServer' - create a constant pool of threads, simplified
61
# 'ThreadingServer' - serve each request in a new thread. Much
62
# slower for static files.
63
# 'ForkingServer' - serve each request on a new child process -
65
# 'SimpleServer' - server one request at a time. Fast, low
67
# If you set one of the threading servers and threads are not
68
# available, the server will fallback to ForkingServer. If fork is
69
# not available, the server will fallback to SimpleServer.
70
serverClass = 'ThreadPoolServer'
72
# Thread limit (default 10)
73
# Limit the number of threads created. Ignored on non threaded servers.
76
# Request queue size (default 50)
77
# The size of the socket listen backlog.
81
# Allow overriding any request property by the value defined in
82
# this dict e.g properties = {'script_name': '/mywiki'}.
85
# Memory profile (default commented)
86
# Useful only if you are a developer or interested in moin memory usage
87
# A memory profile named 'moin--2004-09-27--01-24.log' is
88
# created each time you start the server.
89
## from MoinMoin.util.profile import Profiler
90
## memoryProfile = Profiler(name, requestsPerSample=100, collect=0)
92
# Hotshot profile (default commented)
93
# Not compatible with threads - use with SimpleServer only.
94
## hotshotProfile = name + '.prof'
97
if __name__ == '__main__':