diff options
Diffstat (limited to 'eggs/djangorecipe-0.20-py2.6.egg/djangorecipe/fcgi.py')
-rw-r--r-- | eggs/djangorecipe-0.20-py2.6.egg/djangorecipe/fcgi.py | 29 |
1 files changed, 0 insertions, 29 deletions
diff --git a/eggs/djangorecipe-0.20-py2.6.egg/djangorecipe/fcgi.py b/eggs/djangorecipe-0.20-py2.6.egg/djangorecipe/fcgi.py deleted file mode 100644 index 17a793e..0000000 --- a/eggs/djangorecipe-0.20-py2.6.egg/djangorecipe/fcgi.py +++ /dev/null @@ -1,29 +0,0 @@ -from django.core import management - -def main(settings_file, logfile=None): - try: - mod = __import__(settings_file) - components = settings_file.split('.') - for comp in components[1:]: - mod = getattr(mod, comp) - - except ImportError, e: - import sys - sys.stderr.write("Error loading the settings module '%s': %s" - % (settings_file, e)) - sys.exit(1) - - # Setup settings - management.setup_environ(mod) - - from django.conf import settings - - options = getattr(settings, 'FCGI_OPTIONS', {}) - if logfile: - options['outlog'] = logfile - options['errlog'] = logfile - - from django.core.servers.fastcgi import runfastcgi - - # Run FASTCGI handler - runfastcgi(**options) |