1 # This file is part of Wolnelektury, licensed under GNU Affero GPLv3 or later.
2 # Copyright © Fundacja Nowoczesna Polska. See NOTICE for more information.
5 from machina import MACHINA_MAIN_TEMPLATE_DIR
6 from .paths import PROJECT_DIR
9 MAINTENANCE_MODE = False
12 # ('Your Name', 'your_email@domain.com'),
17 CONTACT_EMAIL = 'fundacja@nowoczesnapolska.org.pl'
21 'ENGINE': 'django.db.backends.sqlite3', # 'postgresql_psycopg2'
22 'NAME': path.join(PROJECT_DIR, 'dev.db'),
23 'USER': '', # Not used with sqlite3.
24 'PASSWORD': '', # Not used with sqlite3.
25 'HOST': '', # Set to empty string for localhost. Not used with sqlite3.
29 SOLR_TEST = "http://localhost:8983/solr/wl_test/"
30 SOLR_STOPWORDS = "/path/to/solr/data/conf/lang/stopwords_pl.txt"
32 # Local time zone for this installation. Choices can be found here:
33 # http://en.wikipedia.org/wiki/List_of_tz_zones_by_name
34 # although not all choices may be available on all operating systems.
35 # If running in a Windows environment this must be set to the same as your
37 TIME_ZONE = 'Europe/Warsaw'
43 'BACKEND': 'django.template.backends.django.DjangoTemplates',
45 path.join(PROJECT_DIR, 'templates'), # Duplicate, because of Machina<1 weird configuration.
46 MACHINA_MAIN_TEMPLATE_DIR,
50 ('django.template.loaders.cached.Loader', (
51 'django.template.loaders.filesystem.Loader',
52 'django.template.loaders.app_directories.Loader',
55 'context_processors': (
56 'django.contrib.auth.context_processors.auth',
57 'django.contrib.messages.context_processors.messages',
58 'django.template.context_processors.debug',
59 'django.template.context_processors.i18n',
60 'django.template.context_processors.media',
61 'django.template.context_processors.request',
62 'wolnelektury.context_processors.extra_settings',
63 'wolnelektury.abtests.context_processor',
64 'search.context_processors.search_form',
65 'machina.core.context_processors.metadata',
71 'debug_toolbar.middleware.DebugToolbarMiddleware',
72 'django.middleware.csrf.CsrfViewMiddleware',
73 'django.middleware.cache.UpdateCacheMiddleware',
74 'django.middleware.common.CommonMiddleware',
75 'django.contrib.sessions.middleware.SessionMiddleware',
76 'django.contrib.auth.middleware.AuthenticationMiddleware',
77 'django.contrib.admindocs.middleware.XViewMiddleware',
78 'fnp_django_pagination.middleware.PaginationMiddleware',
79 'django.middleware.locale.LocaleMiddleware',
80 'maintenancemode.middleware.MaintenanceModeMiddleware',
81 'django.middleware.common.CommonMiddleware',
82 'django.contrib.messages.middleware.MessageMiddleware',
83 'fnpdjango.middleware.SetRemoteAddrFromXRealIP',
84 'django.middleware.cache.FetchFromCacheMiddleware',
85 'machina.apps.forum_permission.middleware.ForumPermissionMiddleware',
88 ROOT_URLCONF = 'wolnelektury.urls'
90 FILE_UPLOAD_PERMISSIONS = 0o640