X-Git-Url: https://git.mdrn.pl/wolnelektury.git/blobdiff_plain/24721591455e048cffca365384e6759daae05916..f9a071b288cec64a55000125a63b62a3b233c3fd:/src/wolnelektury/settings/basic.py?ds=sidebyside diff --git a/src/wolnelektury/settings/basic.py b/src/wolnelektury/settings/basic.py index 47a2388c1..11eb7cfe4 100644 --- a/src/wolnelektury/settings/basic.py +++ b/src/wolnelektury/settings/basic.py @@ -2,7 +2,6 @@ # Copyright © Fundacja Nowoczesna Polska. See NOTICE for more information. # from os import path -from machina import MACHINA_MAIN_TEMPLATE_DIR from .paths import PROJECT_DIR DEBUG = True @@ -15,6 +14,8 @@ MANAGERS = ADMINS CONTACT_EMAIL = 'fundacja@nowoczesnapolska.org.pl' +CACHE_MIDDLEWARE_SECONDS = 24 * 60 * 60 + DATABASES = { 'default': { 'ENGINE': 'django.db.backends.sqlite3', # 'postgresql_psycopg2' @@ -25,6 +26,8 @@ DATABASES = { } } +DEFAULT_AUTO_FIELD = 'django.db.models.AutoField' + SOLR_TEST = "http://localhost:8983/solr/wl_test/" SOLR_STOPWORDS = "/path/to/solr/data/conf/lang/stopwords_pl.txt" @@ -40,17 +43,8 @@ SITE_ID = 1 TEMPLATES = [{ 'BACKEND': 'django.template.backends.django.DjangoTemplates', - 'DIRS': ( - path.join(PROJECT_DIR, 'templates'), # Duplicate, because of Machina<1 weird configuration. - MACHINA_MAIN_TEMPLATE_DIR, - ), + 'APP_DIRS': True, 'OPTIONS': { - 'loaders': ( - ('django.template.loaders.cached.Loader', ( - 'django.template.loaders.filesystem.Loader', - 'django.template.loaders.app_directories.Loader', - )), - ), 'context_processors': ( 'django.contrib.auth.context_processors.auth', 'django.contrib.messages.context_processors.messages', @@ -60,7 +54,6 @@ TEMPLATES = [{ 'django.template.context_processors.request', 'wolnelektury.context_processors.extra_settings', 'search.context_processors.search_form', - 'machina.core.context_processors.metadata', ), }, }] @@ -79,7 +72,6 @@ MIDDLEWARE = [ 'django.contrib.messages.middleware.MessageMiddleware', 'fnpdjango.middleware.SetRemoteAddrFromXRealIP', 'django.middleware.cache.FetchFromCacheMiddleware', - 'machina.apps.forum_permission.middleware.ForumPermissionMiddleware', 'experiments.middleware.experiments_middleware', ]