58e90b9ecc91b7561624dcc16ffbc94f40cb76ed
[auf_savoirs_en_partage_django.git] / auf_savoirs_en_partage / settings.py
1 # -*- encoding: utf-8 -*-
2
3 import os
4 from conf import *
5
6 ADMINS = (
7 ('Équipe ARI-SI', 'developpeurs@ca.auf.org'),
8 )
9
10 MANAGERS = ADMINS
11
12 TIME_ZONE = 'America/Chicago'
13
14 LANGUAGE_CODE = 'fr-ca'
15
16 # Absolute path to the directory that holds media.
17 # Example: "/home/media/media.lawrence.com/"
18 MEDIA_ROOT = os.path.join(os.path.dirname(__file__), 'media')
19
20 # URL that handles the media served from MEDIA_ROOT. Make sure to use a
21 # trailing slash if there is a path component (optional in other cases).
22 # Examples: "http://media.lawrence.com", "http://example.com/media/"
23 MEDIA_URL = '/media/'
24
25 # URL prefix for admin media -- CSS, JavaScript and images. Make sure to use a
26 # trailing slash.
27 # Examples: "http://foo.com/media/", "/media/".
28 ADMIN_MEDIA_PREFIX = '/admin_media/'
29
30 # List of callables that know how to import templates from various sources.
31 TEMPLATE_LOADERS = (
32 'django.template.loaders.filesystem.load_template_source',
33 'django.template.loaders.app_directories.load_template_source',
34 # 'django.template.loaders.eggs.load_template_source',
35 )
36
37 TEMPLATE_CONTEXT_PROCESSORS = (
38 'django.core.context_processors.auth',
39 'django.core.context_processors.debug',
40 'django.core.context_processors.i18n',
41 'django.core.context_processors.media',
42 'django.core.context_processors.request',
43 )
44
45
46 MIDDLEWARE_CLASSES = (
47 'django.middleware.cache.UpdateCacheMiddleware',
48 'django.middleware.common.CommonMiddleware',
49 'django.middleware.cache.FetchFromCacheMiddleware',
50 'django.contrib.sessions.middleware.SessionMiddleware',
51 'django.contrib.auth.middleware.AuthenticationMiddleware',
52 'pagination.middleware.PaginationMiddleware',
53 'django_sorting.middleware.SortingMiddleware',
54 'django.middleware.doc.XViewMiddleware',
55 )
56
57 ROOT_URLCONF = 'auf_savoirs_en_partage.urls'
58
59
60 INSTALLED_APPS = (
61 'admin_tools',
62 'admin_tools.theming',
63 'admin_tools.menu',
64 'admin_tools.dashboard',
65 'django.contrib.auth',
66 'django.contrib.contenttypes',
67 'django.contrib.sessions',
68 'django.contrib.admin',
69 'pagination',
70 'django_sorting',
71 'django_roa',
72 'savoirs',
73 'chercheurs',
74 'sitotheque',
75 )
76
77
78 TEMPLATE_CONTEXT_PROCESSORS = (
79 # default : http://docs.djangoproject.com/en/dev/ref/settings/?from=olddocs#template-context-processors
80 "django.core.context_processors.auth",
81 "django.core.context_processors.debug",
82 "django.core.context_processors.i18n",
83 "django.core.context_processors.media",
84 "django.core.context_processors.request",
85 "context_processors.user_chercheur",
86 )
87 TEMPLATE_LOADERS = (
88 'django.template.loaders.filesystem.load_template_source',
89 'django.template.loaders.app_directories.load_template_source',
90 )
91
92 TEMPLATE_DIRS = (
93 os.path.join(os.path.dirname(__file__), "templates"),
94 )
95
96 AUTHENTICATION_BACKENDS = (
97 'authentification.CascadeBackend',
98 )
99
100 CACHE_BACKEND = 'memcached://127.0.0.1:11211/'
101
102 ROA_CUSTOM_ARGS = {'api-key': ROA_API_KEY}
103
104 ADMIN_TOOLS_INDEX_DASHBOARD = 'auf_savoirs_en_partage.dashboard.CustomIndexDashboard'
105
106 AUTH_PROFILE_MODULE = 'savoirs.Profile'
107
108 CONTACT_EMAIL = 'contact-savoirsenpartage@auf.org'
109
110 from auf_references_client.settings import *