forked from django-haystack/django-haystack
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsettings.py
More file actions
33 lines (31 loc) · 1023 Bytes
/
settings.py
File metadata and controls
33 lines (31 loc) · 1023 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
# All the normal settings apply. What's included here are the bits you'll have
# to customize.
# Add Haystack to INSTALLED_APPS. You can do this by simply placing in your list.
INSTALLED_APPS = INSTALLED_APPS + [
'haystack',
]
import os
HAYSTACK_CONNECTIONS = {
'default': {
# For Solr:
'ENGINE': 'haystack.backends.solr_backend.SolrEngine',
'URL': 'http://localhost:9001/solr/example',
'TIMEOUT': 60 * 5,
'INCLUDE_SPELLING': True,
},
'whoosh': {
# For Whoosh:
'ENGINE': 'haystack.backends.whoosh_backend.WhooshEngine',
'PATH': os.path.join(os.path.dirname(__file__), 'whoosh_index'),
'INCLUDE_SPELLING': True,
},
'simple': {
# For Simple:
'ENGINE': 'haystack.backends.simple_backend.SimpleEngine',
},
'xapian': {
# For Xapian (requires the third-party install):
'ENGINE': 'xapian_backend.XapianEngine',
'PATH': os.path.join(os.path.dirname(__file__), 'xapian_index'),
}
}