From 3b1c188ff8386d70786e206f146d68c6c1af442f Mon Sep 17 00:00:00 2001 From: Dan Scott Date: Wed, 11 Jul 2012 09:46:10 -0400 Subject: [PATCH] Prep for use in mod_wsgi Signed-off-by: Dan Scott --- tools/patron-load/webui.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/tools/patron-load/webui.py b/tools/patron-load/webui.py index c3af4fcf0c..6eb2a1fde2 100644 --- a/tools/patron-load/webui.py +++ b/tools/patron-load/webui.py @@ -1,6 +1,11 @@ #!/usr/bin/env python "A simple Web UI based on the web.py framework" +import sys, os +abspath = os.path.dirname(__file__) +sys.path.append(abspath) +os.chdir(abspath) + import web import ldap_osrf_sync @@ -56,3 +61,6 @@ class LDAP_ARGS: if __name__ == "__main__": app = web.application(urls, globals()) app.run() + +app = web.application(urls, globals(), autoreload=False) +application = app.wsgifunc() -- 2.11.0