blob: 7289653c12442b9f3db33aee947041c0795b60b4 [file] [log] [blame]
showard35444862008-08-07 22:35:30 +00001# Django settings for new_tko project.
2
3import common
4from autotest_lib.client.common_lib import global_config
5
6DEBUG = True
7TEMPLATE_DEBUG = DEBUG
8
9ADMINS = (
10 # ('Your Name', 'your_email@domain.com'),
11)
12
13MANAGERS = ADMINS
14
showarda5288b42009-07-28 20:06:08 +000015DATABASE_ENGINE = 'mysql' # 'postgresql_psycopg2', 'postgresql',
showard35444862008-08-07 22:35:30 +000016 # 'mysql', 'sqlite3' or 'ado_mssql'.
17DATABASE_PORT = '' # Set to empty string for default.
18 # Not used with sqlite3.
19
20c = global_config.global_config
21_section = 'TKO'
22DATABASE_HOST = c.get_config_value(_section, "host")
23# Or path to database file if using sqlite3.
24DATABASE_NAME = c.get_config_value(_section, "database")
25# The following not used with sqlite3.
26DATABASE_USER = c.get_config_value(_section, "user")
showard7a37db12009-01-08 23:31:08 +000027DATABASE_PASSWORD = c.get_config_value(_section, "password", default='')
showard35444862008-08-07 22:35:30 +000028
showard1a573ca2008-09-11 01:32:03 +000029DATABASE_READONLY_HOST = c.get_config_value(_section, "readonly_host",
30 default=DATABASE_HOST)
showard35444862008-08-07 22:35:30 +000031DATABASE_READONLY_USER = c.get_config_value(_section, "readonly_user",
32 default=DATABASE_USER)
showard7a37db12009-01-08 23:31:08 +000033if DATABASE_READONLY_USER != DATABASE_USER:
34 DATABASE_READONLY_PASSWORD = c.get_config_value(_section,
35 "readonly_password",
36 default='')
37else:
38 DATABASE_READONLY_PASSWORD = DATABASE_PASSWORD
showard35444862008-08-07 22:35:30 +000039
40# prefix applied to all URLs - useful if requests are coming through apache,
41# and you need this app to coexist with others
42URL_PREFIX = 'new_tko/server/'
43
44# Local time zone for this installation. Choices can be found here:
45# http://www.postgresql.org/docs/8.1/static/datetime-keywords.html#DATETIME-TIMEZONE-SET-TABLE
46# although not all variations may be possible on all operating systems.
47# If running in a Windows environment this must be set to the same as your
48# system time zone.
49TIME_ZONE = 'America/Los_Angeles'
50
51# Language code for this installation. All choices can be found here:
52# http://www.w3.org/TR/REC-html40/struct/dirlang.html#langcodes
53# http://blogs.law.harvard.edu/tech/stories/storyReader$15
54LANGUAGE_CODE = 'en-us'
55
56SITE_ID = 1
57
58# If you set this to False, Django will make some optimizations so as not
59# to load the internationalization machinery.
60USE_I18N = True
61
62# Absolute path to the directory that holds media.
63# Example: "/home/media/media.lawrence.com/"
64MEDIA_ROOT = ''
65
66# URL that handles the media served from MEDIA_ROOT.
67# Example: "http://media.lawrence.com"
68MEDIA_URL = ''
69
70# URL prefix for admin media -- CSS, JavaScript and images. Make sure to use a
71# trailing slash.
72# Examples: "http://foo.com/media/", "/media/".
73ADMIN_MEDIA_PREFIX = '/media/'
74
75# Make this unique, and don't share it with anybody.
76SECRET_KEY = 't5h^o%emw-1#ga4tvcb82)8irk^w5kyy348osow#$=&3c%60@r'
77
78# List of callables that know how to import templates from various sources.
79TEMPLATE_LOADERS = (
80 'django.template.loaders.filesystem.load_template_source',
81 'django.template.loaders.app_directories.load_template_source',
82# 'django.template.loaders.eggs.load_template_source',
83)
84
85MIDDLEWARE_CLASSES = (
86 'django.middleware.common.CommonMiddleware',
87 'django.contrib.sessions.middleware.SessionMiddleware',
88 'autotest_lib.frontend.apache_auth.GetApacheUserMiddleware',
89 'django.middleware.doc.XViewMiddleware',
90)
91
92ROOT_URLCONF = 'new_tko.urls'
93
94TEMPLATE_DIRS = (
95 # Put strings here, like "/home/html/django_templates" or "C:/www/django/templates".
96 # Always use forward slashes, even on Windows.
97 # Don't forget to use absolute paths, not relative paths.
98)
99
100INSTALLED_APPS = (
101 'new_tko.tko',
102 'django.contrib.contenttypes',
103 'django.contrib.sessions',
104 'django.contrib.sites',
105)