Deploying to gh-pages from @ 547478089f 🚀

This commit is contained in:
kvch 2021-04-07 21:24:26 +00:00
parent b427c03fe4
commit 37d9813444
12 changed files with 332 additions and 13 deletions

View File

@ -12,3 +12,4 @@ Blog
intro-offline
private-engines
command-line-engines
search-indexer-engines

View File

@ -0,0 +1,114 @@
===============================
Query your local search engines
===============================
From now on, searx lets you to query your locally running search engines. The following
ones are supported now:
* `Elasticsearch`_
* `Meilisearch`_
* `Solr`_
All of the engines above are added to ``settings.yml`` just commented out, as you have to
``base_url`` for all them.
Please note that if you are not using HTTPS to access these engines, you have to enable
HTTP requests by setting ``enable_http`` to ``True``.
Futhermore, if you do not want to expose these engines on a public instance, you can
still add them and limit the access by setting ``tokens`` as described in the `blog post about
private engines`_.
Configuring searx for search engines
====================================
Each search engine is powerful, capable of full-text search.
Elasticsearch
-------------
Elasticsearch supports numerous ways to query the data it is storing. At the moment
the engine supports the most popular search methods: ``match``, ``simple_query_string``, ``term`` and ``terms``.
If none of the methods fit your use case, you can select ``custom`` query type and provide the JSON payload
searx has to submit to Elasticsearch in ``custom_query_json``.
The following is an example configuration for an Elasticsearch instance with authentication
configured to read from ``my-index`` index.
.. code:: yaml
- name : elasticsearch
shortcut : es
engine : elasticsearch
base_url : http://localhost:9200
username : elastic
password : changeme
index : my-index
query_type : match
enable_http : True
Meilisearch
-----------
This search engine is aimed at individuals and small companies. It is designed for
small-scale (less than 10 million documents) data collections. E.g. it is great for storing
web pages you have visited and searching in the contents later.
The engine supports faceted search, so you can search in a subset of documents of the collection.
Futhermore, you can search in Meilisearch instances that require authentication by setting ``auth_token``.
Here is a simple example to query a Meilisearch instance:
.. code:: yaml
- name : meilisearch
engine : meilisearch
shortcut: mes
base_url : http://localhost:7700
index : my-index
enable_http: True
Solr
----
Solr is a popular search engine based on Lucene, just like Elasticsearch.
But instead of searching in indices, you can search in collections.
This is an example configuration for searching in the collection ``my-collection`` and get
the results in ascending order.
.. code:: yaml
- name : solr
engine : solr
shortcut : slr
base_url : http://localhost:8983
collection : my-collection
sort : asc
enable_http : True
Next steps
==========
The next step is to add support for various SQL databases.
Acknowledgement
===============
This development was sponsored by `Search and Discovery Fund`_ of `NLnet Foundation`_ .
.. _blog post about private engines: private-engines.html#private-engines
.. _Elasticsearch: https://www.elastic.co/elasticsearch/
.. _Meilisearch: https://www.meilisearch.com/
.. _Solr: https://solr.apache.org/
.. _Search and Discovery Fund: https://nlnet.nl/discovery
.. _NLnet Foundation: https://nlnet.nl/
| Happy hacking.
| kvch // 2021.04.07 23:16

View File

@ -16,6 +16,7 @@
<script src="../_static/doctools.js"></script>
<link rel="index" title="Index" href="../genindex.html" />
<link rel="search" title="Search" href="../search.html" />
<link rel="next" title="Query your local search engines" href="search-indexer-engines.html" />
<link rel="prev" title="Limit access to your searx engines" href="private-engines.html" />
<script>DOCUMENTATION_OPTIONS.URL_ROOT = '../';</script>
@ -29,6 +30,9 @@
<li class="right" >
<a href="../py-modindex.html" title="Python Module Index"
>modules</a> |</li>
<li class="right" >
<a href="search-indexer-engines.html" title="Query your local search engines"
accesskey="N">next</a> |</li>
<li class="right" >
<a href="private-engines.html" title="Limit access to your searx engines"
accesskey="P">previous</a> |</li>
@ -129,7 +133,7 @@ are going to be added. This way, you will be able to query your own databases/in
<li><a href="index.html">Blog</a>
<ul>
<li>Previous: <a href="private-engines.html" title="previous chapter">Limit access to your searx engines</a>
</ul>
<li>Next: <a href="search-indexer-engines.html" title="next chapter">Query your local search engines</a></ul>
</li>
</ul>
</li>

View File

@ -89,6 +89,12 @@
<li class="toctree-l2"><a class="reference internal" href="command-line-engines.html#acknowledgement">Acknowledgement</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="search-indexer-engines.html">Query your local search engines</a><ul>
<li class="toctree-l2"><a class="reference internal" href="search-indexer-engines.html#configuring-searx-for-search-engines">Configuring searx for search engines</a></li>
<li class="toctree-l2"><a class="reference internal" href="search-indexer-engines.html#next-steps">Next steps</a></li>
<li class="toctree-l2"><a class="reference internal" href="search-indexer-engines.html#acknowledgement">Acknowledgement</a></li>
</ul>
</li>
</ul>
</div>
</section>

View File

@ -0,0 +1,193 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Query your local search engines &#8212; Searx Documentation (Searx-1.0.0.tex)</title>
<link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
<link rel="stylesheet" href="../_static/searx.css" type="text/css" />
<link rel="stylesheet" type="text/css" href="../_static/tabs.css" />
<script id="documentation_options" data-url_root="../" src="../_static/documentation_options.js"></script>
<script src="../_static/jquery.js"></script>
<script src="../_static/underscore.js"></script>
<script src="../_static/doctools.js"></script>
<link rel="index" title="Index" href="../genindex.html" />
<link rel="search" title="Search" href="../search.html" />
<link rel="prev" title="Running shell commands to fetch results" href="command-line-engines.html" />
<script>DOCUMENTATION_OPTIONS.URL_ROOT = '../';</script>
</head><body>
<div class="related" role="navigation" aria-label="related navigation">
<h3>Navigation</h3>
<ul>
<li class="right" style="margin-right: 10px">
<a href="../genindex.html" title="General Index"
accesskey="I">index</a></li>
<li class="right" >
<a href="../py-modindex.html" title="Python Module Index"
>modules</a> |</li>
<li class="right" >
<a href="command-line-engines.html" title="Running shell commands to fetch results"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Searx Documentation (Searx-1.0.0.tex)</a> &#187;</li>
<li class="nav-item nav-item-1"><a href="index.html" accesskey="U">Blog</a> &#187;</li>
<li class="nav-item nav-item-this"><a href="">Query your local search engines</a></li>
</ul>
</div>
<div class="document">
<div class="documentwrapper">
<div class="bodywrapper">
<div class="body" role="main">
<section id="query-your-local-search-engines">
<h1>Query your local search engines<a class="headerlink" href="#query-your-local-search-engines" title="Permalink to this headline"></a></h1>
<p>From now on, searx lets you to query your locally running search engines. The following
ones are supported now:</p>
<ul class="simple">
<li><p><a class="reference external" href="https://www.elastic.co/elasticsearch/">Elasticsearch</a></p></li>
<li><p><a class="reference external" href="https://www.meilisearch.com/">Meilisearch</a></p></li>
<li><p><a class="reference external" href="https://solr.apache.org/">Solr</a></p></li>
</ul>
<p>All of the engines above are added to <code class="docutils literal notranslate"><span class="pre">settings.yml</span></code> just commented out, as you have to
<code class="docutils literal notranslate"><span class="pre">base_url</span></code> for all them.</p>
<p>Please note that if you are not using HTTPS to access these engines, you have to enable
HTTP requests by setting <code class="docutils literal notranslate"><span class="pre">enable_http</span></code> to <code class="docutils literal notranslate"><span class="pre">True</span></code>.</p>
<p>Futhermore, if you do not want to expose these engines on a public instance, you can
still add them and limit the access by setting <code class="docutils literal notranslate"><span class="pre">tokens</span></code> as described in the <a class="reference external" href="private-engines.html#private-engines">blog post about
private engines</a>.</p>
<section id="configuring-searx-for-search-engines">
<h2>Configuring searx for search engines<a class="headerlink" href="#configuring-searx-for-search-engines" title="Permalink to this headline"></a></h2>
<p>Each search engine is powerful, capable of full-text search.</p>
<section id="elasticsearch">
<h3>Elasticsearch<a class="headerlink" href="#elasticsearch" title="Permalink to this headline"></a></h3>
<p>Elasticsearch supports numerous ways to query the data it is storing. At the moment
the engine supports the most popular search methods: <code class="docutils literal notranslate"><span class="pre">match</span></code>, <code class="docutils literal notranslate"><span class="pre">simple_query_string</span></code>, <code class="docutils literal notranslate"><span class="pre">term</span></code> and <code class="docutils literal notranslate"><span class="pre">terms</span></code>.</p>
<p>If none of the methods fit your use case, you can select <code class="docutils literal notranslate"><span class="pre">custom</span></code> query type and provide the JSON payload
searx has to submit to Elasticsearch in <code class="docutils literal notranslate"><span class="pre">custom_query_json</span></code>.</p>
<p>The following is an example configuration for an Elasticsearch instance with authentication
configured to read from <code class="docutils literal notranslate"><span class="pre">my-index</span></code> index.</p>
<div class="highlight-yaml notranslate"><div class="highlight"><pre><span></span><span class="p p-Indicator">-</span> <span class="nt">name </span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">elasticsearch</span>
<span class="nt">shortcut </span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">es</span>
<span class="nt">engine </span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">elasticsearch</span>
<span class="nt">base_url </span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">http://localhost:9200</span>
<span class="nt">username </span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">elastic</span>
<span class="nt">password </span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">changeme</span>
<span class="nt">index </span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">my-index</span>
<span class="nt">query_type </span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">match</span>
<span class="nt">enable_http </span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">True</span>
</pre></div>
</div>
</section>
<section id="meilisearch">
<h3>Meilisearch<a class="headerlink" href="#meilisearch" title="Permalink to this headline"></a></h3>
<p>This search engine is aimed at individuals and small companies. It is designed for
small-scale (less than 10 million documents) data collections. E.g. it is great for storing
web pages you have visited and searching in the contents later.</p>
<p>The engine supports faceted search, so you can search in a subset of documents of the collection.
Futhermore, you can search in Meilisearch instances that require authentication by setting <code class="docutils literal notranslate"><span class="pre">auth_token</span></code>.</p>
<p>Here is a simple example to query a Meilisearch instance:</p>
<div class="highlight-yaml notranslate"><div class="highlight"><pre><span></span><span class="p p-Indicator">-</span> <span class="nt">name </span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">meilisearch</span>
<span class="nt">engine </span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">meilisearch</span>
<span class="nt">shortcut</span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">mes</span>
<span class="nt">base_url </span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">http://localhost:7700</span>
<span class="nt">index </span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">my-index</span>
<span class="nt">enable_http</span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">True</span>
</pre></div>
</div>
</section>
<section id="solr">
<h3>Solr<a class="headerlink" href="#solr" title="Permalink to this headline"></a></h3>
<p>Solr is a popular search engine based on Lucene, just like Elasticsearch.
But instead of searching in indices, you can search in collections.</p>
<p>This is an example configuration for searching in the collection <code class="docutils literal notranslate"><span class="pre">my-collection</span></code> and get
the results in ascending order.</p>
<div class="highlight-yaml notranslate"><div class="highlight"><pre><span></span><span class="p p-Indicator">-</span> <span class="nt">name </span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">solr</span>
<span class="nt">engine </span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">solr</span>
<span class="nt">shortcut </span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">slr</span>
<span class="nt">base_url </span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">http://localhost:8983</span>
<span class="nt">collection </span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">my-collection</span>
<span class="nt">sort </span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">asc</span>
<span class="nt">enable_http </span><span class="p">:</span> <span class="l l-Scalar l-Scalar-Plain">True</span>
</pre></div>
</div>
</section>
</section>
<section id="next-steps">
<h2>Next steps<a class="headerlink" href="#next-steps" title="Permalink to this headline"></a></h2>
<p>The next step is to add support for various SQL databases.</p>
</section>
<section id="acknowledgement">
<h2>Acknowledgement<a class="headerlink" href="#acknowledgement" title="Permalink to this headline"></a></h2>
<p>This development was sponsored by <a class="reference external" href="https://nlnet.nl/discovery">Search and Discovery Fund</a> of <a class="reference external" href="https://nlnet.nl/">NLnet Foundation</a> .</p>
<div class="line-block">
<div class="line">Happy hacking.</div>
<div class="line">kvch // 2021.04.07 23:16</div>
</div>
</section>
</section>
<div class="clearer"></div>
</div>
</div>
</div>
<span id="sidebar-top"></span>
<div class="sphinxsidebar" role="navigation" aria-label="main navigation">
<div class="sphinxsidebarwrapper">
<p class="logo"><a href="../index.html">
<img class="logo" src="../_static/searx_logo_small.png" alt="Logo"/>
</a></p>
<h3>Project Links</h3>
<ul>
<li><a href="https://github.com/searx/searx">Source</a>
<li><a href="https://github.com/searx/searx/wiki">Wiki</a>
<li><a href="https://searx.space">Public instances</a>
<li><a href="https://twitter.com/Searx_engine">Twitter</a>
<li><a href="https://github.com/searx/searx/issues">Issue Tracker</a>
</ul><h3>Navigation</h3>
<ul>
<li><a href="../index.html">Overview</a>
<ul>
<li><a href="index.html">Blog</a>
<ul>
<li>Previous: <a href="command-line-engines.html" title="previous chapter">Running shell commands to fetch results</a>
</ul>
</li>
</ul>
</li>
</ul>
<div id="searchbox" style="display: none" role="search">
<h3 id="searchlabel">Quick search</h3>
<div class="searchformwrapper">
<form class="search" action="../search.html" method="get">
<input type="text" name="q" aria-labelledby="searchlabel" />
<input type="submit" value="Go" />
</form>
</div>
</div>
<script>$('#searchbox').show(0);</script>
</div>
</div>
<div class="clearer"></div>
</div>
<div class="footer" role="contentinfo">
&#169; Copyright 2015-2020, Adam Tauber, Noémi Ványi.
Created using <a href="https://www.sphinx-doc.org/">Sphinx</a> 3.5.3.
</div>
<script src="../_static/version_warning_offset.js"></script>
</body>
</html>

View File

@ -123,6 +123,7 @@ digital rights</p></li>
<li class="toctree-l2"><a class="reference internal" href="blog/intro-offline.html">Preparation for offline engines</a></li>
<li class="toctree-l2"><a class="reference internal" href="blog/private-engines.html">Limit access to your searx engines</a></li>
<li class="toctree-l2"><a class="reference internal" href="blog/command-line-engines.html">Running shell commands to fetch results</a></li>
<li class="toctree-l2"><a class="reference internal" href="blog/search-indexer-engines.html">Query your local search engines</a></li>
</ul>
</li>
</ul>

Binary file not shown.

File diff suppressed because one or more lines are too long

View File

@ -184,18 +184,18 @@ inspect service
show service status and log
option
set one of the available options
apache (http://fv-az240-240/searx)
apache (http://fv-az238-705/searx)
:install: apache site with a reverse proxy (ProxyPass)
:remove: apache site searx.conf
nginx (http://fv-az240-240/searx)
nginx (http://fv-az238-705/searx)
:install: nginx site with a reverse proxy (ProxyPass)
:remove: nginx site searx.conf
filtron rules: /etc/filtron/rules.json
If needed, set PUBLIC_URL of your WEB service in the &#39;.config.sh&#39; file::
PUBLIC_URL : http://fv-az240-240/searx
PUBLIC_HOST : fv-az240-240
PUBLIC_URL : http://fv-az238-705/searx
PUBLIC_HOST : fv-az238-705
SERVICE_USER : filtron
FILTRON_TARGET : 127.0.0.1:8888
FILTRON_API : 127.0.0.1:4005

View File

@ -194,7 +194,7 @@ install
:base: prepare LXC; install basic packages
:suite: install LXC searx suite into all (or &lt;name&gt;) containers
LXC suite: searx --&gt; http://fv-az240-240/searx
LXC suite: searx --&gt; http://fv-az238-705/searx
suite includes searx, morty &amp; filtron
suite images:
ubu1804 ubu2004 ubu2010 fedora33 archlinux centos7

View File

@ -186,22 +186,22 @@ inspect service
option
set one of the available options
:new-key: set new morty key
apache : http://fv-az240-240/morty/
apache : http://fv-az238-705/morty/
:install: apache site with a reverse proxy (ProxyPass)
:remove: apache site morty.conf
nginx (http://fv-az240-240/morty/)
nginx (http://fv-az238-705/morty/)
:install: nginx site with a reverse proxy (ProxyPass)
:remove: nginx site morty.conf
If needed, set the environment variables in the &#39;.config.sh&#39; file::
PUBLIC_URL_MORTY: http://fv-az240-240/morty/
PUBLIC_URL_MORTY: http://fv-az238-705/morty/
MORTY_LISTEN: 127.0.0.1:3000
SERVICE_USER: morty
To activate result and image proxy in searx, edit settings.yml (read:
https://searx.github.io/searx/admin/morty.html)::
result_proxy:
url : http://fv-az240-240/morty/
url : http://fv-az238-705/morty/
server:
image_proxy : True
</pre></div>

View File

@ -113,8 +113,8 @@ apache
searx settings: /etc/searx/settings.yml
If needed, set PUBLIC_URL of your WEB service in the &#39;.config.sh&#39; file::
PUBLIC_URL : http://fv-az240-240/searx
SEARX_INSTANCE_NAME : searx@fv-az240-240
PUBLIC_URL : http://fv-az238-705/searx
SEARX_INSTANCE_NAME : searx@fv-az238-705
SERVICE_USER : searx
SEARX_INTERNAL_HTTP : http://127.0.0.1:8888
</pre></div>