changeset 3581:357cea7b7780

remove old moin daemonizing script (replaced by moin server standalone --start/stop), renamed wiki/server/moin.py to wikiserver.py and updated its content from the toplevel clone of it
author Thomas Waldmann <tw AT waldmann-edv DOT de>
date Sun, 11 May 2008 22:46:39 +0200
parents fc2f05f2b0bd
children 27ba7445b480
files wiki/server/moin wiki/server/moin.py wiki/server/wikiserver.py
diffstat 3 files changed, 39 insertions(+), 48 deletions(-) [+]
line wrap: on
line diff
--- a/wiki/server/moin	Sun May 11 22:42:05 2008 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,21 +0,0 @@
-#!/usr/bin/env python
-"""
-    moin - control MoinMoin Standalone server
-
-    If you want to use this to put standalone in daemon mode,
-    you also need moin.py which is the standalone moin script itself.
-                      
-    @copyright: 2004-2005 Thomas Waldmann, Nir Soffer
-    @license: GNU GPL, see COPYING for details.
-"""
-
-# Add the path to moin.py directory 
-## import sys
-## sys.path.insert(0, '/path/to/moin')
-
-from MoinMoin.server import daemon
-from moin import Config, run
-
-script = daemon.DaemonScript(Config.name, run, Config)
-script.run()
-
--- a/wiki/server/moin.py	Sun May 11 22:42:05 2008 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,27 +0,0 @@
-#!/usr/bin/env python
-"""
-    Start script for the standalone Wiki server.
-
-    @copyright: 2007 MoinMoin:ForrestVoight,
-                2008 MoinMoin:ThomasWaldmann
-    @license: GNU GPL, see COPYING for details.
-"""
-
-import os, sys
-
-# Path to MoinMoin package, needed if you installed with --prefix=PREFIX
-# or if you did not use setup.py.
-#sys.path.insert(0, 'PREFIX/lib/python2.3/site-packages')
-
-moinpath = os.path.abspath(os.path.normpath(os.path.dirname(sys.argv[0])))
-sys.path.insert(0, moinpath)
-os.chdir(moinpath)
-
-from MoinMoin import log
-log.load_config('wiki/config/logging/stderr') # XXX please fix this path!
-
-from MoinMoin.script import MoinScript
-
-if __name__ == '__main__':
-    sys.argv = ["moin.py", "server", "standalone"]
-    MoinScript().run()
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/wiki/server/wikiserver.py	Sun May 11 22:46:39 2008 +0200
@@ -0,0 +1,39 @@
+#!/usr/bin/env python
+"""
+    Start script for the standalone Wiki server.
+
+    @copyright: 2007 MoinMoin:ForrestVoight
+    @license: GNU GPL, see COPYING for details.
+"""
+
+import sys, os
+
+# a) Configuration of Python's code search path
+#    If you already have set up the PYTHONPATH environment variable for the
+#    stuff you see below, you don't need to do a1) and a2).
+
+# a1) Path of the directory where the MoinMoin code package is located.
+#     Needed if you installed with --prefix=PREFIX or you didn't use setup.py.
+#sys.path.insert(0, 'PREFIX/lib/python2.3/site-packages')
+
+# a2) Path of the directory where wikiconfig.py / farmconfig.py is located.
+moinpath = os.path.abspath(os.path.normpath(os.path.dirname(sys.argv[0])))
+sys.path.insert(0, moinpath)
+os.chdir(moinpath)
+
+# b) Configuration of moin's logging
+#    If you have set up MOINLOGGINGCONF environment variable, you don't need this!
+#    You also don't need this if you are happy with the builtin defaults.
+#    See wiki/config/logging/... for some sample config files.
+from MoinMoin import log
+log.load_config('wikiserverlogging.conf')
+
+# Debug mode - show detailed error reports
+#os.environ['MOIN_DEBUG'] = '1'
+
+from MoinMoin.script import MoinScript
+
+if __name__ == '__main__':
+    sys.argv = ["moin.py", "server", "standalone"]
+    MoinScript().run()
+