préparation de la nouvelle app
[ongolaboy.git] / projets_django / bacgl_django / bacgl_django / settings.py
CommitLineData
adc90da7
O
1import conf
2
3# Django settings for bacgl_django project.
4
5DEBUG = True
6TEMPLATE_DEBUG = DEBUG
7
8ADMINS = (
9 # ('Your Name', 'your_email@example.com'),
10)
11
12MANAGERS = ADMINS
13
14DATABASES = {
15 'default': {
16 'ENGINE': 'django.db.backends.mysql', # Add 'postgresql_psycopg2', 'mysql', 'sqlite3' or 'oracle'.
17 'NAME': conf.DB, # Or path to database file if using sqlite3.
18 'USER': conf.USER, # Not used with sqlite3.
19 'PASSWORD': conf.PASSWORD, # Not used with sqlite3.
20 'HOST': conf.HOST, # Set to empty string for localhost. Not used with sqlite3.
21 'PORT': '', # Set to empty string for default. Not used with sqlite3.
cdf15ebb
O
22 },
23 'ancienneBD': {
24 'ENGINE': 'django.db.backends.mysql', # Add 'postgresql_psycopg2', 'mysql', 'sqlite3' or 'oracle'.
25 'NAME': conf.DB0, # Or path to database file if using sqlite3.
26 'USER': conf.USER0, # Not used with sqlite3.
27 'PASSWORD': conf.PASSWORD0, # Not used with sqlite3.
28 'HOST': conf.HOST0, # Set to empty string for localhost. Not used with sqlite3.
29 'PORT': '', # Set to empty string for default. Not used with sqlite3.
adc90da7
O
30 }
31}
32
302583d1
O
33DATABASE_ROUTERS=['bacgl_django.db.AncienRoutage',]
34
adc90da7
O
35# Hosts/domain names that are valid for this site; required if DEBUG is False
36# See https://docs.djangoproject.com/en//ref/settings/#allowed-hosts
37ALLOWED_HOSTS = []
38
39# Local time zone for this installation. Choices can be found here:
40# http://en.wikipedia.org/wiki/List_of_tz_zones_by_name
41# although not all choices may be available on all operating systems.
42# In a Windows environment this must be set to your system time zone.
43TIME_ZONE = 'Africa/Douala'
44
45# Language code for this installation. All choices can be found here:
46# http://www.i18nguy.com/unicode/language-identifiers.html
47LANGUAGE_CODE = 'fr-fr'
48
49SITE_ID = 1
50
51# If you set this to False, Django will make some optimizations so as not
52# to load the internationalization machinery.
53USE_I18N = True
54
55# If you set this to False, Django will not format dates, numbers and
56# calendars according to the current locale.
57USE_L10N = True
58
59# If you set this to False, Django will not use timezone-aware datetimes.
60USE_TZ = True
61
62# Absolute filesystem path to the directory that will hold user-uploaded files.
63# Example: "/home/media/media.lawrence.com/media/"
64MEDIA_ROOT = ''
65
66# URL that handles the media served from MEDIA_ROOT. Make sure to use a
67# trailing slash.
68# Examples: "http://media.lawrence.com/media/", "http://example.com/media/"
69MEDIA_URL = ''
70
71# Absolute path to the directory static files should be collected to.
72# Don't put anything in this directory yourself; store your static files
73# in apps' "static/" subdirectories and in STATICFILES_DIRS.
74# Example: "/home/media/media.lawrence.com/static/"
75STATIC_ROOT = ''
76
77# URL prefix for static files.
78# Example: "http://media.lawrence.com/static/"
79STATIC_URL = '/static/'
80
81# Additional locations of static files
82STATICFILES_DIRS = (
83 # Put strings here, like "/home/html/static" or "C:/www/django/static".
84 # Always use forward slashes, even on Windows.
85 # Don't forget to use absolute paths, not relative paths.
86)
87
88# List of finder classes that know how to find static files in
89# various locations.
90STATICFILES_FINDERS = (
91 'django.contrib.staticfiles.finders.FileSystemFinder',
92 'django.contrib.staticfiles.finders.AppDirectoriesFinder',
93# 'django.contrib.staticfiles.finders.DefaultStorageFinder',
94)
95
96# Make this unique, and don't share it with anybody.
97SECRET_KEY = '^)vh8pdplh8d8-mk%dt$j-ta%fo_ra^b5gb(u_wlkd4y1&5opz'
98
99# List of callables that know how to import templates from various sources.
100TEMPLATE_LOADERS = (
101 'django.template.loaders.filesystem.Loader',
102 'django.template.loaders.app_directories.Loader',
103# 'django.template.loaders.eggs.Loader',
104)
105
106MIDDLEWARE_CLASSES = (
107 'django.middleware.common.CommonMiddleware',
108 'django.contrib.sessions.middleware.SessionMiddleware',
109 'django.middleware.csrf.CsrfViewMiddleware',
110 'django.contrib.auth.middleware.AuthenticationMiddleware',
111 'django.contrib.messages.middleware.MessageMiddleware',
112 # Uncomment the next line for simple clickjacking protection:
113 # 'django.middleware.clickjacking.XFrameOptionsMiddleware',
114)
115
116ROOT_URLCONF = 'bacgl_django.urls'
117
118# Python dotted path to the WSGI application used by Django's runserver.
119WSGI_APPLICATION = 'bacgl_django.wsgi.application'
120
121TEMPLATE_DIRS = (
122 # Put strings here, like "/home/html/django_templates" or "C:/www/django/templates".
123 # Always use forward slashes, even on Windows.
124 # Don't forget to use absolute paths, not relative paths.
125)
126
127INSTALLED_APPS = (
128 'django.contrib.auth',
129 'django.contrib.contenttypes',
130 'django.contrib.sessions',
9554f767 131 #'django.contrib.sites',
adc90da7
O
132 'django.contrib.messages',
133 'django.contrib.staticfiles',
9554f767 134 'south',
cdf15ebb 135 'ancien_messagerie',
adc90da7 136 # Uncomment the next line to enable the admin:
48daa321 137 'django.contrib.admin',
adc90da7
O
138 # Uncomment the next line to enable admin documentation:
139 # 'django.contrib.admindocs',
140)
141
142# A sample logging configuration. The only tangible logging
143# performed by this configuration is to send an email to
144# the site admins on every HTTP 500 error when DEBUG=False.
145# See http://docs.djangoproject.com/en/dev/topics/logging for
146# more details on how to customize your logging configuration.
147LOGGING = {
148 'version': 1,
149 'disable_existing_loggers': False,
150 'filters': {
151 'require_debug_false': {
152 '()': 'django.utils.log.RequireDebugFalse'
153 }
154 },
155 'handlers': {
156 'mail_admins': {
157 'level': 'ERROR',
158 'filters': ['require_debug_false'],
159 'class': 'django.utils.log.AdminEmailHandler'
160 }
161 },
162 'loggers': {
163 'django.request': {
164 'handlers': ['mail_admins'],
165 'level': 'ERROR',
166 'propagate': True,
167 },
168 }
169}