python $manage telemeta-create-admin-user
python $manage telemeta-create-boilerplate
-if [ $REINDEX = "True"]
+if [ $REINDEX = "True" ]
then
python $manage rebuild_index --noinput
fi
HAYSTACK_CONNECTIONS = {
'default': {
- 'ENGINE': 'telemeta.util.backend.CustomElasticEngine',
+ 'ENGINE': 'haystack.backends.elasticsearch_backend.ElasticsearchSearchEngine',
'URL': 'http://search:9200/',
'INDEX_NAME': 'haystack',
'INLUDE_SPELLING': True,
--- /dev/null
+3a6f83feeb737d406aea74e03ae989969a5af9ff
\ No newline at end of file
# Thomas Fillon <thomas@parisson.com>
app:
- env_file:
- ./index.env
+ env_file:
+ env/index.env
+++ /dev/null
-from haystack.backends.elasticsearch_backend import *
-
-class CustomElasticBackend(ElasticsearchSearchBackend):
-
- def setup(self):
- FIELD_MAPPINGS.get('edge_ngram')['search_analyzer']="standard";
- FIELD_MAPPINGS.get('ngram')['search_analyzer']="standard";
- eb = super(CustomElasticBackend, self)
- eb.DEFAULT_SETTINGS.get('settings').get('analysis').get('filter').get('haystack_ngram')['max_gram']=30
- eb.setup()
-
-class CustomElasticEngine(ElasticsearchSearchEngine):
- backend = CustomElasticBackend
\ No newline at end of file