source: src/django_gheat/settings.py@ 9385

Last change on this file since 9385 was 9385, checked in by rick, 13 years ago

Not using the special OSM_CACHE anymore, get rid of it

File size: 4.3 KB
RevLine 
[9041]1# Django settings for persisted project.
2
3import os
[9189]4PROJECT_HOME = os.path.abspath(os.path.dirname(__file__))
[9372]5
[9385]6DEBUG = os.path.exists(PROJECT_HOME + '/enable-debug')
[9041]7TEMPLATE_DEBUG = DEBUG
8
[9188]9# Required for Etags Caching Implementation
10USE_ETAGS = True
11
[9041]12ADMINS = (
[9368]13 ('Rick van der Zwet', 'info@rickvanderzwet.nl'),
[9041]14)
15
16MANAGERS = ADMINS
17
18DATABASES = {
19 'default': {
[9051]20 'ENGINE': 'django.db.backends.mysql',
21 'NAME': 'project_heatmap',
22 'USER': 'root',
[9358]23 'PASSWORD': '',
[9051]24 'HOST': 'localhost',
25 'PORT': '3306',
[9041]26 }
27}
28
[9188]29CACHES = {
30 'default': {
[9385]31 'BACKEND': 'django.core.cache.backends.memcached.MemcachedCache',
32 'LOCATION': '127.0.0.1:11211',
[9189]33 'TIMEOUT': 3600 * 24 * 7,
34 'OPTIONS': {
35 'MAX_ENTRIES': 100000
36 }
[9385]37 },
[9188]38}
39
40
[9041]41# Local time zone for this installation. Choices can be found here:
42# http://en.wikipedia.org/wiki/List_of_tz_zones_by_name
43# although not all choices may be available on all operating systems.
44# If running in a Windows environment this must be set to the same as your
45# system time zone.
46TIME_ZONE = 'America/Chicago'
47
48# Language code for this installation. All choices can be found here:
49# http://www.i18nguy.com/unicode/language-identifiers.html
50LANGUAGE_CODE = 'en-us'
51
52SITE_ID = 1
53
54# If you set this to False, Django will make some optimizations so as not
55# to load the internationalization machinery.
56USE_I18N = True
57
58# Absolute path to the directory that holds media.
59# Example: "/home/media/media.lawrence.com/"
60MEDIA_ROOT = ''
61
62# URL that handles the media served from MEDIA_ROOT. Make sure to use a
63# trailing slash if there is a path component (optional in other cases).
64# Examples: "http://media.lawrence.com", "http://example.com/media/"
65MEDIA_URL = ''
66
67# URL prefix for admin media -- CSS, JavaScript and images. Make sure to use a
68# trailing slash.
69# Examples: "http://foo.com/media/", "/media/".
70ADMIN_MEDIA_PREFIX = '/media/'
71
[9139]72# Absolute path to the directory static files should be collected to.
73# Don't put anything in this directory yourself; store your static files
74# in apps' "static/" subdirectories and in STATICFILES_DIRS.
75# Example: "/home/media/media.lawrence.com/static/"
[9358]76STATIC_ROOT = 'sitestatic'
[9139]77
78# URL prefix for static files.
79# Example: "http://media.lawrence.com/static/"
80STATIC_URL = '/static/'
81
82# URL prefix for admin static files -- CSS, JavaScript and images.
83# Make sure to use a trailing slash.
84# Examples: "http://foo.com/static/admin/", "/static/admin/".
85ADMIN_MEDIA_PREFIX = '/static/admin/'
86
87# Additional locations of static files
88STATICFILES_DIRS = (
[9358]89 # PROJECT_HOME + '/static',
[9139]90 # Put strings here, like "/home/html/static" or "C:/www/django/static".
91 # Always use forward slashes, even on Windows.
92 # Don't forget to use absolute paths, not relative paths.
93)
94
95# List of finder classes that know how to find static files in
96# various locations.
97STATICFILES_FINDERS = (
98 'django.contrib.staticfiles.finders.FileSystemFinder',
99 'django.contrib.staticfiles.finders.AppDirectoriesFinder',
100# 'django.contrib.staticfiles.finders.DefaultStorageFinder',
101)
102
[9041]103# Make this unique, and don't share it with anybody.
104SECRET_KEY = '=wg@x19kr@26sibiaynb9ax5ddp1&yu^+$3n++^_lz1ms80syb'
105
106# List of callables that know how to import templates from various sources.
107TEMPLATE_LOADERS = (
108 'django.template.loaders.filesystem.load_template_source',
109 'django.template.loaders.app_directories.load_template_source',
[9051]110 'django.template.loaders.eggs.load_template_source',
[9041]111)
112
113MIDDLEWARE_CLASSES = (
[9188]114 'django.middleware.cache.UpdateCacheMiddleware',
[9358]115 'django.middleware.common.CommonMiddleware',
116 'django.middleware.cache.FetchFromCacheMiddleware',
117 'django.middleware.http.ConditionalGetMiddleware',
[9041]118 'django.contrib.sessions.middleware.SessionMiddleware',
119 'django.contrib.auth.middleware.AuthenticationMiddleware',
120)
121
[9139]122ROOT_URLCONF = 'urls'
[9041]123
124TEMPLATE_DIRS = (
125 # Put strings here, like "/home/html/django_templates" or "C:/www/django/templates".
126 # Always use forward slashes, even on Windows.
[9051]127 # Don't forget to use absolute paths, not relative paths.
[9041]128 os.path.join(PROJECT_HOME, 'templates'),
129)
130
131INSTALLED_APPS = (
[9051]132 'django.contrib.admin',
[9041]133 'django.contrib.auth',
134 'django.contrib.contenttypes',
135 'django.contrib.sessions',
136 'django.contrib.sites',
[9358]137 'django.contrib.staticfiles',
[9041]138 'django_extensions',
[9139]139 'gheat',
[9376]140 'wlheatmap',
[9041]141)
Note: See TracBrowser for help on using the repository browser.