searxng/docs/dev/engines/offline/nosql-engines.rst
Markus Heiser 0600cfa34c [furo] remove .. contents:: directives
The directive creates a table of contents for the page.  However, Furo includes
a table of contents already in the sidebar.  It is, thus, recommended to
removing the `.. contents::` directive.

[1] https://github.com/pradyunsg/furo/issues/88#issuecomment-803297274

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2024-04-19 13:24:20 +02:00

2.3 KiB

NoSQL databases

info

Initial sponsored by Search and Discovery Fund of NLnet Foundation.

The following NoSQL databases are supported:

  • engine redis_server
  • engine mongodb

All of the engines above are just commented out in the settings.yml <searx/settings.yml>, as you have to set various options and install dependencies before using them.

By default, the engines use the key-value template for displaying results / see simple <searx/templates/simple/result_templates/key-value.html> theme. If you are not satisfied with the original result layout, you can use your own template, set result_template attribute to {template_name} and place the templates at:

searx/templates/{theme_name}/result_templates/{template_name}

Furthermore, if you do not wish to expose these engines on a public instance, you can still add them and limit the access by setting tokens as described in section private engines.

Extra Dependencies

For using engine redis_server or engine mongodb you need to install additional packages in Python's Virtual Environment of your SearXNG instance. To switch into the environment (searxng-src) you can use searxng.sh:

$ sudo utils/searxng.sh instance cmd bash
(searxng-pyenv)$ pip install ...

Configure the engines

NoSQL databases are used for storing arbitrary data without first defining their structure.

Redis Server

info

  • pip install redis
  • redis.io
  • redis_server.py <searx/engines/redis_server.py>

searx.engines.redis_server

MongoDB

info

searx.engines.mongodb