configurable bot token

This commit is contained in:
2019-01-19 09:52:00 +03:00
parent 33ff1b800b
commit 999c6af8e7
20 changed files with 154 additions and 60 deletions

View File

@@ -26,9 +26,10 @@ INSTALLED_APPS = [
'raven.contrib.django.raven_compat',
'django_extensions',
'bootstrap4',
'djconfig',
'cabinet',
'feeds',
'cabinet.apps.CabinetConfig',
'feeds.apps.FeedsConfig',
]
MIDDLEWARE = [
@@ -39,6 +40,7 @@ MIDDLEWARE = [
'django.contrib.auth.middleware.AuthenticationMiddleware',
'django.contrib.messages.middleware.MessageMiddleware',
'django.middleware.clickjacking.XFrameOptionsMiddleware',
'djconfig.middleware.DjConfigMiddleware',
]
ROOT_URLCONF = 'config.urls'
@@ -54,7 +56,9 @@ TEMPLATES = [
'django.template.context_processors.request',
'django.contrib.auth.context_processors.auth',
'django.contrib.messages.context_processors.messages',
'djconfig.context_processors.config',
'config.utils.turbolinks',
'cabinet.utils.cabinet_context_processor',
],
},
},
@@ -82,6 +86,19 @@ STATICFILES_FINDERS = [
'django.contrib.staticfiles.finders.AppDirectoriesFinder',
]
CACHES = {
"default": {
"BACKEND": "django_redis.cache.RedisCache",
"LOCATION": "redis://127.0.0.1:6379/1",
"OPTIONS": {
"CLIENT_CLASS": "django_redis.client.DefaultClient",
}
}
}
SESSION_ENGINE = "django.contrib.sessions.backends.cache"
SESSION_CACHE_ALIAS = "default"
PUBLIC_ROOT = BASE_DIR.path('public')
STATIC_URL = '/static/'
STATIC_ROOT = str(PUBLIC_ROOT.path('static'))