Frontend demo for django-elasticsearch-dsl-drf
Based on Book model, BookDocument and BookFrontendDocumentViewSet viewset.
From the project root directory.
Since project supports Django versions from 1.8 to 2.1, you may install any version you want.
To install latest LTS version, do:
pip install -r examples/requirements/django_1_11.txtSince project supports Elasticsearch versions from 2.x to 6.x, you may install any version you want.
To install requirements for 6.x, do:
pip install -r examples/requirements/elastic_6x.txtIt's really easy using Docker.
To run 6.3.2 using Docker, do:
docker pull docker.elastic.co/elasticsearch/elasticsearch:6.3.2
docker run -p 9200:9200 -e "discovery.type=single-node" -e "xpack.security.enabled=false" docker.elastic.co/elasticsearch/elasticsearch:6.3.2First, create some test data:
./scripts/create_test_data.shThen build Elasticsearch index:
./scripts/rebuild_index.shNote, that you should be using NodeJS > 7.5.
Typically, you would first do:
nvm use 9Then run the installer:
./scripts/yarn_install.shThe following script would run the Django server which is used by the demo app.
./scripts/runserver.shFinally, run the React demo app:
./scripts/frontend.shOpen http://localhost:3000 to view the frontend in the browser.