4d8b81b9c2e0c52a7e07bf1ef2048b466f5ea3bf
[wolnelektury.git] / wolnelektury / settings / __init__.py
1 # -*- coding: utf-8 -*-
2 # Django settings for wolnelektury project.
3 from os import path
4
5 from settings.basic import *
6 from settings.auth import *
7 from settings.cache import *
8 from settings.celery import *
9 from settings.custom import *
10 from settings.locale import *
11 from settings.static import *
12
13
14 TEMPLATE_CONTEXT_PROCESSORS = (
15     'django.contrib.auth.context_processors.auth',
16     'django.core.context_processors.debug',
17     'django.core.context_processors.i18n',
18     'django.core.context_processors.media',
19     'django.core.context_processors.request',
20     'wolnelektury_core.context_processors.extra_settings',
21     'search.context_processors.search_form',
22     "allauth.context_processors.allauth",
23     "allauth.account.context_processors.account",
24 )
25
26 MIDDLEWARE_CLASSES = [
27     'django.middleware.cache.UpdateCacheMiddleware',
28     'django.middleware.common.CommonMiddleware',
29     'django.contrib.sessions.middleware.SessionMiddleware',
30     'django.contrib.auth.middleware.AuthenticationMiddleware',
31     'django.middleware.doc.XViewMiddleware',
32     'pagination.middleware.PaginationMiddleware',
33     'django.middleware.locale.LocaleMiddleware',
34     'piwik.django.middleware.PiwikMiddleware',
35     'maintenancemode.middleware.MaintenanceModeMiddleware',
36     'django.middleware.common.CommonMiddleware',
37     'django.middleware.cache.FetchFromCacheMiddleware',
38     'django.contrib.messages.middleware.MessageMiddleware',
39 ]
40
41 ROOT_URLCONF = 'wolnelektury.urls'
42
43 INSTALLED_APPS = [
44     # external
45     'django.contrib.auth',
46     'django.contrib.contenttypes',
47     'django.contrib.sessions',
48     'django.contrib.sites',
49     'django.contrib.admin',
50     'django.contrib.admindocs',
51     'pagination',
52     'piston',
53     'piwik.django',
54     #'rosetta',
55     'south',
56     'sorl.thumbnail',
57     'djcelery',
58     'djkombu',
59     #    'django_nose',
60
61     #allauth stuff
62     'emailconfirmation',
63     'uni_form',
64     'allauth',
65     'allauth.account',
66     'allauth.socialaccount',
67     'allauth.openid',
68     #'allauth.facebook',
69     #'allauth.twitter',
70
71     # included
72     'compress',
73     'modeltranslation',
74
75     # our
76     'wolnelektury_core',
77     'ajaxable',
78     'api',
79     'catalogue',
80     'chunks',
81     'dictionary',
82     'infopages',
83     'lesmianator',
84     #'lessons',
85     'newtagging',
86     'opds',
87     'pdcounter',
88     'reporting',
89     'sponsors',
90     'stats',
91     'suggest',
92     'picture',
93     'search',
94     'social',
95 ]
96
97 # Load localsettings, if they exist
98 try:
99     from localsettings import *
100 except ImportError:
101     pass
102