diff options
| author | Markus Heiser <markus.heiser@darmarit.de> | 2019-12-12 11:19:26 +0100 |
|---|---|---|
| committer | Markus Heiser <markus.heiser@darmarit.de> | 2019-12-12 11:19:26 +0100 |
| commit | 49e8dd1e0dbce9b06a3a4ad2de6fc0e1d95eb49b (patch) | |
| tree | 9b947e35abc9325c0c75fff77ec78b7d83a543e3 /docs/blog | |
| parent | 3f93fe04d8c43191cc3bff51c9add1c35728c789 (diff) | |
| parent | 61e9b0b75f9fabb4e50eddcd1aed6592fd2569bd (diff) | |
doc: move patches from /doc folder of branch gh-pages to master
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
Diffstat (limited to 'docs/blog')
| -rw-r--r-- | docs/blog/admin.rst | 42 | ||||
| -rw-r--r-- | docs/blog/blog.rst | 9 | ||||
| -rw-r--r-- | docs/blog/intro-offline.rst | 65 | ||||
| -rw-r--r-- | docs/blog/python3.rst | 54 | ||||
| -rw-r--r-- | docs/blog/searx-admin-engines.png | bin | 0 -> 50840 bytes | |||
| -rw-r--r-- | docs/blog/searxpy3.png | bin | 0 -> 30947 bytes |
6 files changed, 170 insertions, 0 deletions
diff --git a/docs/blog/admin.rst b/docs/blog/admin.rst new file mode 100644 index 000000000..18d5ed33b --- /dev/null +++ b/docs/blog/admin.rst @@ -0,0 +1,42 @@ +Searx admin interface: manage your instance from your browser +============================================================= + +One of the biggest advantages of searx is being extremely customizable. But at first it can be daunting to newcomers. +A barrier of taking advantage of this feature is our ugly settings file which is sometimes hard to understand and edit. + +To make self-hosting searx more accessible a new tool is introduced, called ``searx-admin``. +It is a web application which is capable of managing your instance and manipulating its settings via a web UI. +It aims to replace editing of ``settings.yml`` for less experienced administrators or people +who prefer graphical admin interfaces. + +.. figure:: searx-admin-engines.png + :scale: 50 % + :alt: Screenshot of engine list + :align: center + :figclass: align-center + + Configuration page of engines + + +Since ``searx-admin`` acts as a supervisor for searx, we have decided to implement it +as a standalone tool instead of part of searx. Another reason for making it a standalone +tool is that the codebase and dependencies of searx should not grow because of a fully optional feature, +which does not affect existing instances. + + +Installation +------------ + +Installation guide can be found in the repository of searx-admin: +https://github.com/kvch/searx-admin#installation--usage + +Acknowledgements +---------------- + +This development was sponsored by `NLnet Foundation`_. + +.. _NLnet Foundation: https://nlnet.nl/ + + +| Happy hacking. +| kvch // 2017.08.22 21:25 diff --git a/docs/blog/blog.rst b/docs/blog/blog.rst new file mode 100644 index 000000000..2ccaaa5d3 --- /dev/null +++ b/docs/blog/blog.rst @@ -0,0 +1,9 @@ +Blog +==== + +.. toctree:: + :maxdepth: 1 + + python3 + admin + intro-offline diff --git a/docs/blog/intro-offline.rst b/docs/blog/intro-offline.rst new file mode 100644 index 000000000..914521718 --- /dev/null +++ b/docs/blog/intro-offline.rst @@ -0,0 +1,65 @@ +Preparation for offline engines +=============================== + +Offline engines +--------------- + +To extend the functionality of searx, offline engines are going to be introduced. An offline engine is an engine which does not need Internet connection to perform a search and does not use HTTP to communicate. + +Offline engines can be configured as online engines, by adding those to the `engines` list of `settings.yml`. Thus, searx finds the engine file and imports it. + +Example skeleton for the new engines: + +.. code:: python + + from subprocess import PIPE, Popen + + categories = ['general'] + offline = True + + def init(settings): + pass + + def search(query, params): + process = Popen(['ls', query], stdout=PIPE) + return_code = process.wait() + if return_code != 0: + raise RuntimeError('non-zero return code', return_code) + + results = [] + line = process.stdout.readline() + while line: + result = parse_line(line) + results.append(results) + + line = process.stdout.readline() + + return results + + +Development progress +-------------------- + +First, a proposal has been created as a Github issue. Then it was moved to the wiki as a design document. You can read it here: https://github.com/asciimoo/searx/wiki/Offline-engines + +In this development step, searx core was prepared to accept and perform offline searches. Offline search requests are scheduled together with regular offline requests. + +As offline searches can return arbitrary results depending on the engine, the current result templates were insufficient to present such results. Thus, a new template is introduced which is caplable of presenting arbitrary key value pairs as a table. You can check out the pull request for more details: https://github.com/asciimoo/searx/pull/1700 + +Next steps +---------- + +Today, it is possible to create/run an offline engine. However, it is going to be publicly available for everyone who knows the searx instance. So the next step is to introduce token based access for engines. This way administrators are able to limit the access to private engines. + +Acknowledgement +--------------- + +This development was sponsored by `Search and Discovery Fund`_ of `NLnet Foundation`_ . + +.. _Search and Discovery Fund: https://nlnet.nl/discovery +.. _NLnet Foundation: https://nlnet.nl/ + + +| Happy hacking. +| kvch // 2019.10.21 17:03 + diff --git a/docs/blog/python3.rst b/docs/blog/python3.rst new file mode 100644 index 000000000..eb14a49eb --- /dev/null +++ b/docs/blog/python3.rst @@ -0,0 +1,54 @@ +Introducing Python3 support +=========================== + +As most operation systems are coming with Python3 installed by default. So it is time for searx to support Python3. But don't worry support of Python2.7 won't be dropped. + +.. image:: searxpy3.png + :scale: 50 % + :alt: hurray + :align: center + + +How to run searx using Python3 +------------------------------ + +Please make sure that you run at least Python3.5. + +To run searx, first a Python3 virtualenv should be created. After entering the virtualenv, +dependencies must be installed. Then run searx with python3 instead of the usual python command. + +.. code:: sh + + virtualenv -p python3 venv3 + source venv3/bin/activate + pip3 install -r requirements.txt + python3 searx/webapp.py + + +If you want to run searx using Python2.7, you don't have to do anything differently as before. + +Fun facts +--------- + +- 115 files were changed when implementing the support for both Python versions. + +- All of the dependencies was compatible except for the robotframework used for browser tests. Thus, these tests were migrated to splinter. So from now on both versions are being tested on Travis and can be tested locally. + +If you found bugs... +-------------------- + +...please open an issue on `GitHub`_. Make sure that you mention your Python version in your issue, +so we can investigate it properly. + +.. _GitHub: https://github.com/asciimoo/searx/issues + +Acknowledgement +--------------- + +This development was sponsored by `NLnet Foundation`_. + +.. _NLnet Foundation: https://nlnet.nl/ + + +| Happy hacking. +| kvch // 2017.05.13 22:57 diff --git a/docs/blog/searx-admin-engines.png b/docs/blog/searx-admin-engines.png Binary files differnew file mode 100644 index 000000000..610bacdf7 --- /dev/null +++ b/docs/blog/searx-admin-engines.png diff --git a/docs/blog/searxpy3.png b/docs/blog/searxpy3.png Binary files differnew file mode 100644 index 000000000..8eeaeec55 --- /dev/null +++ b/docs/blog/searxpy3.png |