~ubuntu-branches/debian/sid/dico/sid

« back to all changes in this revision

Viewing changes to .pc/dicoweb-django.diff/dicoweb/settings-sample.py

  • Committer: Package Import Robot
  • Author(s): أحمد المحمودي (Ahmed El-Mahmoudy)
  • Date: 2012-06-29 11:03:01 UTC
  • Revision ID: package-import@ubuntu.com-20120629110301-8wh8cbbcw0uvmynh
Tags: 2.2-2
* debian/rules: Enable all hardening flags.
* Added dicoweb-django.diff patch to replace deprecated load_template_source
  callers. (Closes: #678912)

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#  Django settings for Dicoweb project.
 
2
#
 
3
#  This file is part of GNU Dico.
 
4
#  Copyright (C) 2008-2010, 2012 Wojciech Polak
 
5
#
 
6
#  GNU Dico is free software; you can redistribute it and/or modify
 
7
#  it under the terms of the GNU General Public License as published by
 
8
#  the Free Software Foundation; either version 3, or (at your option)
 
9
#  any later version.
 
10
#
 
11
#  GNU Dico is distributed in the hope that it will be useful,
 
12
#  but WITHOUT ANY WARRANTY; without even the implied warranty of
 
13
#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
14
#  GNU General Public License for more details.
 
15
#
 
16
#  You should have received a copy of the GNU General Public License
 
17
#  along with GNU Dico.  If not, see <http://www.gnu.org/licenses/>.
 
18
 
 
19
import os
 
20
SITE_ROOT = os.path.dirname (os.path.realpath (__file__))
 
21
 
 
22
DEBUG = False
 
23
TEMPLATE_DEBUG = False
 
24
 
 
25
# Please define this correctly
 
26
ADMINS = (
 
27
    ('Dico Admin', 'root@localhost'),
 
28
)
 
29
MANAGERS = ADMINS
 
30
 
 
31
DATABASE_ENGINE = ''
 
32
DATABASE_NAME = ''
 
33
DATABASE_USER = ''
 
34
DATABASE_PASSWORD = ''
 
35
DATABASE_HOST = ''
 
36
DATABASE_PORT = ''
 
37
 
 
38
SITE_ID = 1
 
39
USE_I18N = True
 
40
 
 
41
# Please define this correctly
 
42
TIME_ZONE = 'Europe/Warsaw'
 
43
LANGUAGE_CODE = 'en-us'
 
44
LANGUAGE_COOKIE_NAME = 'dicoweb_lang'
 
45
 
 
46
SESSION_COOKIE_NAME = 'dicoweb_sid'
 
47
SESSION_ENGINE = 'django.contrib.sessions.backends.file'
 
48
SESSION_EXPIRE_AT_BROWSER_CLOSE = True
 
49
 
 
50
# Caching, see http://docs.djangoproject.com/en/dev/topics/cache/#topics-cache
 
51
CACHE_BACKEND = 'memcached://127.0.0.1:11211/'
 
52
 
 
53
# Absolute path to the directory that holds media/static files.
 
54
MEDIA_ROOT = os.path.join (SITE_ROOT, 'static')
 
55
 
 
56
# URL that handles the media served from MEDIA_ROOT.
 
57
MEDIA_URL = 'static'
 
58
 
 
59
# Make this unique, and don't share it with anybody.
 
60
SECRET_KEY = 'SET THIS TO A RANDOM STRING'
 
61
 
 
62
# List of callables that know how to import templates from various sources.
 
63
TEMPLATE_LOADERS = (
 
64
    'django.template.loaders.filesystem.load_template_source',
 
65
    'django.template.loaders.app_directories.load_template_source',
 
66
)
 
67
 
 
68
MIDDLEWARE_CLASSES = (
 
69
    'django.middleware.cache.UpdateCacheMiddleware',
 
70
    'django.contrib.sessions.middleware.SessionMiddleware',
 
71
    'django.middleware.locale.LocaleMiddleware',
 
72
    'django.middleware.gzip.GZipMiddleware',
 
73
    'django.middleware.common.CommonMiddleware',
 
74
    'django.middleware.cache.FetchFromCacheMiddleware',
 
75
)
 
76
 
 
77
ROOT_URLCONF = 'dicoweb.urls'
 
78
 
 
79
TEMPLATE_DIRS = (
 
80
    os.path.join (SITE_ROOT, 'templates'),
 
81
)
 
82
 
 
83
INSTALLED_APPS = (
 
84
    'django.contrib.contenttypes',
 
85
    'django.contrib.sessions',
 
86
    'django.contrib.sites',
 
87
    'dicoweb',
 
88
)
 
89
 
 
90
DICT_SERVERS = ('localhost',)
 
91
DICT_TIMEOUT = 10