summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRob Crittenden <rcritten@redhat.com>2009-06-18 16:29:22 -0400
committerRob Crittenden <rcritten@redhat.com>2009-06-18 16:29:22 -0400
commitd658e88f635fa84341e71d2de9151a37e1c69914 (patch)
treed35acc7761b43262f926b7b6003e1b57f3a0e292
parent50bfc94cd7d2451dc1420ac672355b9a4c9d7688 (diff)
downloadfreeipa-d658e88f635fa84341e71d2de9151a37e1c69914.tar.gz
freeipa-d658e88f635fa84341e71d2de9151a37e1c69914.tar.xz
freeipa-d658e88f635fa84341e71d2de9151a37e1c69914.zip
Make the UI work when both python-cherrypy and python-cherrypy2 are installed
Also shut down logging different in ipa_webui. Rather than calling logging.shutdown() pull all the log handlers and close them. 505686
-rw-r--r--ipa-server/ipa-gui/ipa_webgui7
1 files changed, 6 insertions, 1 deletions
diff --git a/ipa-server/ipa-gui/ipa_webgui b/ipa-server/ipa-gui/ipa_webgui
index 677fc9a5..e38479f0 100644
--- a/ipa-server/ipa-gui/ipa_webgui
+++ b/ipa-server/ipa-gui/ipa_webgui
@@ -17,6 +17,8 @@
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
#
+__requires__ = 'TurboGears'
+
import os, sys, pwd, grp
from optparse import OptionParser
import traceback
@@ -175,7 +177,10 @@ def main():
# Shut down the logging set up here so that CherryPy logging can take
# over. TurboGears configuration errors will not be caught.
if not foreground:
- logging.shutdown()
+ l = logging.getLogger()
+ for h in logging.root.handlers:
+ l.removeHandler(h)
+
# Load the config - look for a local file first for development
# and then the system config file