README.rst 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157
  1. searx
  2. =====
  3. A privacy-respecting, hackable `metasearch
  4. engine <https://en.wikipedia.org/wiki/Metasearch_engine>`__.
  5. List of `running
  6. instances <https://github.com/asciimoo/searx/wiki/Searx-instances>`__.
  7. |Flattr searx|
  8. Features
  9. ~~~~~~~~
  10. - Tracking free
  11. - Supports multiple output formats
  12. - json ``curl https://searx.0x2a.tk/?format=json&q=[query]``
  13. - csv ``curl https://searx.0x2a.tk/?format=csv&q=[query]``
  14. - opensearch/rss ``curl https://searx.0x2a.tk/?format=rss&q=[query]``
  15. - Opensearch support (you can set as default search engine)
  16. - Configurable search engines/categories
  17. - Duckduckgo like !bang functionality with engine shortcuts
  18. - Parallel queries - relatively fast
  19. Installation
  20. ~~~~~~~~~~~~
  21. - clone source:
  22. ``git clone git@github.com:asciimoo/searx.git && cd searx``
  23. - install dependencies: ``pip install -r requirements.txt``
  24. - edit your
  25. `settings.yml <https://github.com/asciimoo/searx/blob/master/settings.yml>`__
  26. (set your ``secret_key``!)
  27. - run ``python searx/webapp.py`` to start the application
  28. For all the details, follow this `step by step
  29. installation <https://github.com/asciimoo/searx/wiki/Installation>`__
  30. Alternative (Recommended) Installation
  31. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  32. - clone source:
  33. ``git clone git@github.com:asciimoo/searx.git && cd searx``
  34. - build in current folder: ``make minimal``
  35. - run ``bin/searx-run`` to start the application
  36. Development
  37. ~~~~~~~~~~~
  38. Just run ``make``. Versions of dependencies are pinned down inside
  39. ``versions.cfg`` to produce most stable build. Also remember, NO make
  40. command should be run as root, not even ``make production``
  41. Deployment
  42. ~~~~~~~~~~
  43. - clone source:
  44. ``git clone git@github.com:asciimoo/searx.git && cd searx``
  45. - build in current folder: ``make production``
  46. - run ``bin/supervisord`` to start the application
  47. Upgrading
  48. ~~~~~~~~~
  49. - inside previously cloned searx directory run: ``git stash`` to
  50. temporarily save any changes you have made
  51. - pull source: ``git pull origin master``
  52. - re-build in current folder: ``make production``
  53. - run ``bin/supervisorctl stop searx`` to stop searx, if it does not,
  54. then run ``fuser -k 8888/tcp``
  55. - run ``bin/supervisorctl reload`` to re-read supervisor config and
  56. start searx
  57. Command make
  58. ~~~~~~~~~~~~
  59. ``make``
  60. ''''''''
  61. Builds development environment with testing support.
  62. ``make tests``
  63. ''''''''''''''
  64. Runs tests. You can write tests
  65. `here <https://github.com/asciimoo/searx/tree/master/searx/tests>`__ and
  66. remember 'untested code is broken code'.
  67. ``make robot``
  68. ''''''''''''''
  69. Runs robot (Selenium) tests, you must have ``firefox`` installed because
  70. this functional tests actually run the browser and perform operations on
  71. it. Also searx is executed with
  72. `settings\_robot <https://github.com/asciimoo/searx/blob/master/searx/settings_robot.py>`__.
  73. ``make flake8``
  74. '''''''''''''''
  75. 'pep8 is a tool to check your Python code against some of the style
  76. conventions in `PEP 8 <http://www.python.org/dev/peps/pep-0008/>`__.'
  77. ``make coverage``
  78. '''''''''''''''''
  79. Checks coverage of tests, after running this, execute this:
  80. ``firefox ./coverage/index.html``
  81. ``make production``
  82. '''''''''''''''''''
  83. Used to make co-called production environment - without tests (you
  84. should ran tests before deploying searx on the server). This installs
  85. supervisord, so if searx crashes, it will try to pick itself up again.
  86. And crontab entry is added to start supervisord at server boot.
  87. ``make minimal``
  88. ''''''''''''''''
  89. Minimal build - without test frameworks, the quickest build option.
  90. ``make clean``
  91. ''''''''''''''
  92. Deletes several folders and files (see ``Makefile`` for more), so that
  93. next time you run any other ``make`` command it will rebuild everithing.
  94. TODO
  95. ~~~~
  96. - Moar engines
  97. - Better ui
  98. - Browser integration
  99. - Documentation
  100. - Fix ``flake8`` errors, ``make flake8`` will be merged into
  101. ``make tests`` when it does not fail anymore
  102. - Tests
  103. - When we have more tests, we can integrate Travis-CI
  104. Bugs
  105. ~~~~
  106. Bugs or suggestions? Visit the `issue
  107. tracker <https://github.com/asciimoo/searx/issues>`__.
  108. `License <https://github.com/asciimoo/searx/blob/master/LICENSE>`__
  109. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  110. More about searx
  111. ~~~~~~~~~~~~~~~~
  112. - `ohloh <https://www.ohloh.net/p/searx/>`__
  113. - `twitter <https://twitter.com/Searx_engine>`__
  114. - IRC: #searx @ freenode
  115. .. |Flattr searx| image:: http://api.flattr.com/button/flattr-badge-large.png
  116. :target: https://flattr.com/submit/auto?user_id=asciimoo&url=https://github.com/asciimoo/searx&title=searx&language=&tags=github&category=software