whoosh test

This commit is contained in:
2018-06-15 14:58:37 +02:00
parent 0bed73158f
commit 30613b74ea
2 changed files with 6 additions and 3 deletions

View File

@@ -59,4 +59,7 @@ RUN gulp build
# <STATIC>
RUN DJANGO_MODE=build python manage.py collectstatic --noinput
# </STATIC>
# </STATIC>
RUN mkdir -p /whoosh
RUN chmod a+rwx -R /whoosh

View File

@@ -63,14 +63,14 @@ HAYSTACK_DEFAULT_OPERATOR = 'OR'
HAYSTACK_CONNECTIONS = {
'default': {
'ENGINE': 'haystack.backends.whoosh_backend.WhooshEngine',
'PATH': os.path.join('/tmp/whoosh', 'default'),
'PATH': os.path.join('/whoosh', 'default'),
},
}
for lang_code, lang in LANGUAGES:
HAYSTACK_CONNECTIONS[lang_code] = {}
HAYSTACK_CONNECTIONS[lang_code].update({
'ENGINE': 'haystack.backends.whoosh_backend.WhooshEngine',
'PATH': os.path.join('/tmp/whoosh', lang_code),
'PATH': os.path.join('/whoosh', lang_code),
})
HAYSTACK_ROUTERS = ['aldryn_search.router.LanguageRouter', ]