Local Solr Instance - ccnmtl/footprints Wiki


Docker must be installed in your development environment and be running


  1. Update your local_settings.py with the following stanza
if 'test' not in sys.argv and 'jenkins' not in sys.argv and 'validate' not in sys.argv:
        'default': {
            'ENGINE': 'haystack.backends.solr_backend.SolrEngine',
            'URL': 'http://localhost:8983/solr/footprints',
            'TIMEOUT': 60 * 5,
            'INCLUDE_SPELLING': False,
            'BATCH_SIZE': 10,
  1. Run make docker-solr. (This command pulls down the Docker Solr container and runs the instance, binding to configuration files in the Footprints source tree.)

  2. Verify the Solr instance is running by navigating to http://localhost:8983 in your browser. The Solr dashboard should appear. Footprints should be listed in the core selector on the left-hand side.

  3. From the Footprints source root, run ./manage.py rebuild_index. This will add data in your local Footprints database to the index.

  4. Verify the whole thing works by running Footprints (make runserver) and navigating to the /search/ endpoint. You should see a list of all indexed items.

  5. Use make docker-solr-clean to turn off the instance and cleanup. The data store will remain resident in your development directory.