source: asadb/settings.py @ 06e4045

fysm-4-1iframespace-accessstablestagetest-hooks
Last change on this file since 06e4045 was 06e4045, checked in by Alex Dehnert <adehnert@…>, 15 years ago

Shamelessly lift some config too

  • Property mode set to 100644
File size: 3.1 KB
Line 
1# Django settings for asadb project.
2import os
3import sys
4
5SITE_ROOT = os.path.normpath(os.path.dirname(__file__))
6SITE_WEB_PATH = ''
7
8
9DEBUG = True
10TEMPLATE_DEBUG = DEBUG
11
12ADMINS = (
13    ('ASA Database Team', 'asa-db@mit.edu',),
14)
15
16MANAGERS = ADMINS
17
18DATABASE_ENGINE = ''           # 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'.
19DATABASE_NAME = ''             # Or path to database file if using sqlite3.
20DATABASE_USER = ''             # Not used with sqlite3.
21DATABASE_PASSWORD = ''         # Not used with sqlite3.
22DATABASE_HOST = ''             # Set to empty string for localhost. Not used with sqlite3.
23DATABASE_PORT = ''             # Set to empty string for default. Not used with sqlite3.
24
25ENABLE_SCRIPTS_AUTH = True
26
27# Local time zone for this installation. Choices can be found here:
28# http://en.wikipedia.org/wiki/List_of_tz_zones_by_name
29# although not all choices may be available on all operating systems.
30# If running in a Windows environment this must be set to the same as your
31# system time zone.
32TIME_ZONE = 'America/Chicago'
33
34# Language code for this installation. All choices can be found here:
35# http://www.i18nguy.com/unicode/language-identifiers.html
36LANGUAGE_CODE = 'en-us'
37
38SITE_ID = 1
39
40# If you set this to False, Django will make some optimizations so as not
41# to load the internationalization machinery.
42USE_I18N = True
43
44from local_settings import *
45
46# Absolute path to the directory that holds media.
47# Example: "/home/media/media.lawrence.com/"
48MEDIA_ROOT = SITE_ROOT + '/media/'
49
50# URL that handles the media served from MEDIA_ROOT. Make sure to use a
51# trailing slash if there is a path component (optional in other cases).
52# Examples: "http://media.lawrence.com", "http://example.com/media/"
53MEDIA_URL = SITE_WEB_PATH + '/media/'
54
55# URL prefix for admin media -- CSS, JavaScript and images. Make sure to use a
56# trailing slash.
57# Examples: "http://foo.com/media/", "/media/".
58ADMIN_MEDIA_PREFIX = SITE_WEB_PATH + '/media/admin/'
59
60# List of callables that know how to import templates from various sources.
61TEMPLATE_LOADERS = (
62    'django.template.loaders.filesystem.load_template_source',
63    'django.template.loaders.app_directories.load_template_source',
64#     'django.template.loaders.eggs.load_template_source',
65)
66
67MIDDLEWARE_CLASSES = [
68    'django.middleware.common.CommonMiddleware',
69    'django.contrib.sessions.middleware.SessionMiddleware',
70    'django.contrib.auth.middleware.AuthenticationMiddleware',
71]
72
73AUTHENTICATION_BACKENDS = [
74    'django.contrib.auth.backends.ModelBackend',
75]
76
77if ENABLE_SCRIPTS_AUTH:
78    MIDDLEWARE_CLASSES.append('mit.ScriptsRemoteUserMiddleware')
79    AUTHENTICATION_BACKENDS.insert(0, 'mit.ScriptsRemoteUserBackend')
80
81
82ROOT_URLCONF = 'asadb.urls'
83
84TEMPLATE_DIRS = (
85    # Put strings here, like "/home/html/django_templates" or "C:/www/django/templates".
86    # Always use forward slashes, even on Windows.
87    # Don't forget to use absolute paths, not relative paths.
88    'template',
89)
90
91INSTALLED_APPS = (
92    'django.contrib.admin',
93    'django.contrib.admindocs',
94    'django.contrib.auth',
95    'django.contrib.contenttypes',
96    'django.contrib.sessions',
97    'django.contrib.sites',
98    'groups',
99    'forms',
100)
Note: See TracBrowser for help on using the repository browser.