installation.html 28KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  2. "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  3. <html xmlns="http://www.w3.org/1999/xhtml">
  4. <head>
  5. <meta http-equiv="X-UA-Compatible" content="IE=Edge" />
  6. <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
  7. <title>Installation &#8212; searx 0.12.0 documentation</title>
  8. <link rel="stylesheet" href="../../_static/style.css" type="text/css" />
  9. <link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
  10. <script type="text/javascript" src="../../_static/documentation_options.js"></script>
  11. <script type="text/javascript" src="../../_static/jquery.js"></script>
  12. <script type="text/javascript" src="../../_static/underscore.js"></script>
  13. <script type="text/javascript" src="../../_static/doctools.js"></script>
  14. <link rel="index" title="Index" href="../../genindex.html" />
  15. <link rel="search" title="Search" href="../../search.html" />
  16. <link rel="next" title="Administration API" href="../../admin/api.html" />
  17. <link rel="prev" title="Why use a private instance?" href="../../user/own-instance.html" />
  18. <link media="only screen and (max-device-width: 480px)" href="../../_static/small_flask.css" type= "text/css" rel="stylesheet" />
  19. <meta name="viewport" content="width=device-width, initial-scale=0.9, maximum-scale=0.9">
  20. </head><body>
  21. <div class="document">
  22. <div class="documentwrapper">
  23. <div class="bodywrapper">
  24. <div class="body" role="main">
  25. <div class="section" id="installation">
  26. <span id="id1"></span><h1><a class="toc-backref" href="#id3">Installation</a><a class="headerlink" href="#installation" title="Permalink to this headline">¶</a></h1>
  27. <div class="contents topic" id="contents">
  28. <p class="topic-title first">Contents</p>
  29. <ul class="simple">
  30. <li><a class="reference internal" href="#installation" id="id3">Installation</a><ul>
  31. <li><a class="reference internal" href="#basic-installation" id="id4">Basic installation</a></li>
  32. <li><a class="reference internal" href="#configuration" id="id5">Configuration</a></li>
  33. <li><a class="reference internal" href="#check" id="id6">Check</a></li>
  34. <li><a class="reference internal" href="#uwsgi" id="id7">uwsgi</a></li>
  35. <li><a class="reference internal" href="#web-server" id="id8">Web server</a><ul>
  36. <li><a class="reference internal" href="#with-nginx" id="id9">with nginx</a></li>
  37. <li><a class="reference internal" href="#with-apache" id="id10">with apache</a></li>
  38. </ul>
  39. </li>
  40. <li><a class="reference internal" href="#how-to-update" id="id11">How to update</a></li>
  41. <li><a class="reference internal" href="#docker" id="id12">Docker</a></li>
  42. </ul>
  43. </li>
  44. <li><a class="reference internal" href="#references" id="id13">References</a></li>
  45. </ul>
  46. </div>
  47. <div class="section" id="basic-installation">
  48. <h2><a class="toc-backref" href="#id4">Basic installation</a><a class="headerlink" href="#basic-installation" title="Permalink to this headline">¶</a></h2>
  49. <p>Step by step installation for Debian/Ubuntu with virtualenv. For Ubuntu, be sure to have enable universe repository.</p>
  50. <p>Install packages:</p>
  51. <div class="code sh highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">sudo</span> <span class="n">apt</span><span class="o">-</span><span class="n">get</span> <span class="n">install</span> <span class="n">git</span> <span class="n">build</span><span class="o">-</span><span class="n">essential</span> <span class="n">libxslt</span><span class="o">-</span><span class="n">dev</span> <span class="n">python</span><span class="o">-</span><span class="n">dev</span> <span class="n">python</span><span class="o">-</span><span class="n">virtualenv</span> <span class="n">virtualenv</span> <span class="n">python</span><span class="o">-</span><span class="n">babel</span> <span class="n">zlib1g</span><span class="o">-</span><span class="n">dev</span> <span class="n">libffi</span><span class="o">-</span><span class="n">dev</span> <span class="n">libssl</span><span class="o">-</span><span class="n">dev</span>
  52. </pre></div>
  53. </div>
  54. <p>Install searx:</p>
  55. <div class="code sh highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">cd</span> <span class="o">/</span><span class="n">usr</span><span class="o">/</span><span class="n">local</span>
  56. <span class="n">sudo</span> <span class="n">git</span> <span class="n">clone</span> <span class="n">https</span><span class="p">:</span><span class="o">//</span><span class="n">github</span><span class="o">.</span><span class="n">com</span><span class="o">/</span><span class="n">asciimoo</span><span class="o">/</span><span class="n">searx</span><span class="o">.</span><span class="n">git</span>
  57. <span class="n">sudo</span> <span class="n">useradd</span> <span class="n">searx</span> <span class="o">-</span><span class="n">d</span> <span class="o">/</span><span class="n">usr</span><span class="o">/</span><span class="n">local</span><span class="o">/</span><span class="n">searx</span>
  58. <span class="n">sudo</span> <span class="n">chown</span> <span class="n">searx</span><span class="p">:</span><span class="n">searx</span> <span class="o">-</span><span class="n">R</span> <span class="o">/</span><span class="n">usr</span><span class="o">/</span><span class="n">local</span><span class="o">/</span><span class="n">searx</span>
  59. </pre></div>
  60. </div>
  61. <p>Install dependencies in a virtualenv:</p>
  62. <div class="code sh highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">sudo</span> <span class="o">-</span><span class="n">u</span> <span class="n">searx</span> <span class="o">-</span><span class="n">i</span>
  63. <span class="n">cd</span> <span class="o">/</span><span class="n">usr</span><span class="o">/</span><span class="n">local</span><span class="o">/</span><span class="n">searx</span>
  64. <span class="n">virtualenv</span> <span class="n">searx</span><span class="o">-</span><span class="n">ve</span>
  65. <span class="o">.</span> <span class="o">./</span><span class="n">searx</span><span class="o">-</span><span class="n">ve</span><span class="o">/</span><span class="nb">bin</span><span class="o">/</span><span class="n">activate</span>
  66. <span class="o">./</span><span class="n">manage</span><span class="o">.</span><span class="n">sh</span> <span class="n">update_packages</span>
  67. </pre></div>
  68. </div>
  69. </div>
  70. <div class="section" id="configuration">
  71. <h2><a class="toc-backref" href="#id5">Configuration</a><a class="headerlink" href="#configuration" title="Permalink to this headline">¶</a></h2>
  72. <div class="code sh highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">sed</span> <span class="o">-</span><span class="n">i</span> <span class="o">-</span><span class="n">e</span> <span class="s2">&quot;s/ultrasecretkey/`openssl rand -hex 16`/g&quot;</span> <span class="n">searx</span><span class="o">/</span><span class="n">settings</span><span class="o">.</span><span class="n">yml</span>
  73. </pre></div>
  74. </div>
  75. <p>Edit searx/settings.yml if necessary.</p>
  76. </div>
  77. <div class="section" id="check">
  78. <h2><a class="toc-backref" href="#id6">Check</a><a class="headerlink" href="#check" title="Permalink to this headline">¶</a></h2>
  79. <p>Start searx:</p>
  80. <div class="code sh highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">python</span> <span class="n">searx</span><span class="o">/</span><span class="n">webapp</span><span class="o">.</span><span class="n">py</span>
  81. </pre></div>
  82. </div>
  83. <p>Go to <a class="reference external" href="http://localhost:8888">http://localhost:8888</a></p>
  84. <p>If everything works fine, disable the debug option in settings.yml:</p>
  85. <div class="code sh highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">sed</span> <span class="o">-</span><span class="n">i</span> <span class="o">-</span><span class="n">e</span> <span class="s2">&quot;s/debug : True/debug : False/g&quot;</span> <span class="n">searx</span><span class="o">/</span><span class="n">settings</span><span class="o">.</span><span class="n">yml</span>
  86. </pre></div>
  87. </div>
  88. <p>At this point searx is not demonized ; uwsgi allows this.</p>
  89. <p>You can exit the virtualenv and the searx user bash (enter exit command
  90. twice).</p>
  91. </div>
  92. <div class="section" id="uwsgi">
  93. <h2><a class="toc-backref" href="#id7">uwsgi</a><a class="headerlink" href="#uwsgi" title="Permalink to this headline">¶</a></h2>
  94. <p>Install packages:</p>
  95. <div class="code sh highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">sudo</span> <span class="n">apt</span><span class="o">-</span><span class="n">get</span> <span class="n">install</span> <span class="n">uwsgi</span> <span class="n">uwsgi</span><span class="o">-</span><span class="n">plugin</span><span class="o">-</span><span class="n">python</span>
  96. </pre></div>
  97. </div>
  98. <p>Create the configuration file /etc/uwsgi/apps-available/searx.ini with
  99. this content:</p>
  100. <div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="p">[</span><span class="n">uwsgi</span><span class="p">]</span>
  101. <span class="c1"># Who will run the code</span>
  102. <span class="n">uid</span> <span class="o">=</span> <span class="n">searx</span>
  103. <span class="n">gid</span> <span class="o">=</span> <span class="n">searx</span>
  104. <span class="c1"># disable logging for privacy</span>
  105. <span class="n">disable</span><span class="o">-</span><span class="n">logging</span> <span class="o">=</span> <span class="n">true</span>
  106. <span class="c1"># Number of workers (usually CPU count)</span>
  107. <span class="n">workers</span> <span class="o">=</span> <span class="mi">4</span>
  108. <span class="c1"># The right granted on the created socket</span>
  109. <span class="n">chmod</span><span class="o">-</span><span class="n">socket</span> <span class="o">=</span> <span class="mi">666</span>
  110. <span class="c1"># Plugin to use and interpretor config</span>
  111. <span class="n">single</span><span class="o">-</span><span class="n">interpreter</span> <span class="o">=</span> <span class="n">true</span>
  112. <span class="n">master</span> <span class="o">=</span> <span class="n">true</span>
  113. <span class="n">plugin</span> <span class="o">=</span> <span class="n">python</span>
  114. <span class="n">lazy</span><span class="o">-</span><span class="n">apps</span> <span class="o">=</span> <span class="n">true</span>
  115. <span class="n">enable</span><span class="o">-</span><span class="n">threads</span> <span class="o">=</span> <span class="n">true</span>
  116. <span class="c1"># Module to import</span>
  117. <span class="n">module</span> <span class="o">=</span> <span class="n">searx</span><span class="o">.</span><span class="n">webapp</span>
  118. <span class="c1"># Virtualenv and python path</span>
  119. <span class="n">virtualenv</span> <span class="o">=</span> <span class="o">/</span><span class="n">usr</span><span class="o">/</span><span class="n">local</span><span class="o">/</span><span class="n">searx</span><span class="o">/</span><span class="n">searx</span><span class="o">-</span><span class="n">ve</span><span class="o">/</span>
  120. <span class="n">pythonpath</span> <span class="o">=</span> <span class="o">/</span><span class="n">usr</span><span class="o">/</span><span class="n">local</span><span class="o">/</span><span class="n">searx</span><span class="o">/</span>
  121. <span class="n">chdir</span> <span class="o">=</span> <span class="o">/</span><span class="n">usr</span><span class="o">/</span><span class="n">local</span><span class="o">/</span><span class="n">searx</span><span class="o">/</span><span class="n">searx</span><span class="o">/</span>
  122. </pre></div>
  123. </div>
  124. <p>Activate the uwsgi application and restart:</p>
  125. <div class="code sh highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">cd</span> <span class="o">/</span><span class="n">etc</span><span class="o">/</span><span class="n">uwsgi</span><span class="o">/</span><span class="n">apps</span><span class="o">-</span><span class="n">enabled</span>
  126. <span class="n">ln</span> <span class="o">-</span><span class="n">s</span> <span class="o">../</span><span class="n">apps</span><span class="o">-</span><span class="n">available</span><span class="o">/</span><span class="n">searx</span><span class="o">.</span><span class="n">ini</span>
  127. <span class="o">/</span><span class="n">etc</span><span class="o">/</span><span class="n">init</span><span class="o">.</span><span class="n">d</span><span class="o">/</span><span class="n">uwsgi</span> <span class="n">restart</span>
  128. </pre></div>
  129. </div>
  130. </div>
  131. <div class="section" id="web-server">
  132. <h2><a class="toc-backref" href="#id8">Web server</a><a class="headerlink" href="#web-server" title="Permalink to this headline">¶</a></h2>
  133. <div class="section" id="with-nginx">
  134. <h3><a class="toc-backref" href="#id9">with nginx</a><a class="headerlink" href="#with-nginx" title="Permalink to this headline">¶</a></h3>
  135. <p>If nginx is not installed (uwsgi will not work with the package
  136. nginx-light):</p>
  137. <div class="code sh highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">sudo</span> <span class="n">apt</span><span class="o">-</span><span class="n">get</span> <span class="n">install</span> <span class="n">nginx</span>
  138. </pre></div>
  139. </div>
  140. <div class="section" id="hosted-at">
  141. <h4>Hosted at /<a class="headerlink" href="#hosted-at" title="Permalink to this headline">¶</a></h4>
  142. <p>Create the configuration file /etc/nginx/sites-available/searx with this
  143. content:</p>
  144. <div class="code nginx highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">server</span> <span class="p">{</span>
  145. <span class="n">listen</span> <span class="mi">80</span><span class="p">;</span>
  146. <span class="n">server_name</span> <span class="n">searx</span><span class="o">.</span><span class="n">example</span><span class="o">.</span><span class="n">com</span><span class="p">;</span>
  147. <span class="n">root</span> <span class="o">/</span><span class="n">usr</span><span class="o">/</span><span class="n">local</span><span class="o">/</span><span class="n">searx</span><span class="p">;</span>
  148. <span class="n">location</span> <span class="o">/</span> <span class="p">{</span>
  149. <span class="n">include</span> <span class="n">uwsgi_params</span><span class="p">;</span>
  150. <span class="n">uwsgi_pass</span> <span class="n">unix</span><span class="p">:</span><span class="o">/</span><span class="n">run</span><span class="o">/</span><span class="n">uwsgi</span><span class="o">/</span><span class="n">app</span><span class="o">/</span><span class="n">searx</span><span class="o">/</span><span class="n">socket</span><span class="p">;</span>
  151. <span class="p">}</span>
  152. <span class="p">}</span>
  153. </pre></div>
  154. </div>
  155. <p>Restart service:</p>
  156. <div class="code sh highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">sudo</span> <span class="n">service</span> <span class="n">nginx</span> <span class="n">restart</span>
  157. <span class="n">sudo</span> <span class="n">service</span> <span class="n">uwsgi</span> <span class="n">restart</span>
  158. </pre></div>
  159. </div>
  160. </div>
  161. <div class="section" id="from-subdirectory-url-searx">
  162. <h4>from subdirectory URL (/searx)<a class="headerlink" href="#from-subdirectory-url-searx" title="Permalink to this headline">¶</a></h4>
  163. <p>Add this configuration in the server config file
  164. /etc/nginx/sites-enabled/default:</p>
  165. <div class="code nginx highlight-default notranslate"><div class="highlight"><pre><span></span>location = /searx { rewrite ^ /searx/; }
  166. location /searx {
  167. try_files $uri @searx;
  168. }
  169. location @searx {
  170. uwsgi_param SCRIPT_NAME /searx;
  171. include uwsgi_params;
  172. uwsgi_modifier1 30;
  173. uwsgi_pass unix:/run/uwsgi/app/searx/socket;
  174. }
  175. </pre></div>
  176. </div>
  177. <p>OR</p>
  178. <p>using reverse proxy
  179. (Please, note that reverse proxy advised to be used in case of single-user or low-traffic instances.)</p>
  180. <div class="code nginx highlight-default notranslate"><div class="highlight"><pre><span></span>location /searx {
  181. proxy_pass http://127.0.0.1:8888;
  182. proxy_set_header Host $host;
  183. proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
  184. proxy_set_header X-Scheme $scheme;
  185. proxy_set_header X-Script-Name /searx;
  186. proxy_buffering off;
  187. }
  188. </pre></div>
  189. </div>
  190. <p>Enable base_url in searx/settings.yml</p>
  191. <div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">base_url</span> <span class="p">:</span> <span class="n">http</span><span class="p">:</span><span class="o">//</span><span class="n">your</span><span class="o">.</span><span class="n">domain</span><span class="o">.</span><span class="n">tld</span><span class="o">/</span><span class="n">searx</span><span class="o">/</span>
  192. </pre></div>
  193. </div>
  194. <p>Restart service:</p>
  195. <div class="code sh highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">sudo</span> <span class="n">service</span> <span class="n">nginx</span> <span class="n">restart</span>
  196. <span class="n">sudo</span> <span class="n">service</span> <span class="n">uwsgi</span> <span class="n">restart</span>
  197. </pre></div>
  198. </div>
  199. <div class="section" id="disable-logs">
  200. <h5>disable logs<a class="headerlink" href="#disable-logs" title="Permalink to this headline">¶</a></h5>
  201. <p>for better privacy you can disable nginx logs about searx.</p>
  202. <p>how to proceed: below <code class="docutils literal notranslate"><span class="pre">uwsgi_pass</span></code> in
  203. /etc/nginx/sites-available/default add</p>
  204. <div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">access_log</span> <span class="o">/</span><span class="n">dev</span><span class="o">/</span><span class="n">null</span><span class="p">;</span>
  205. <span class="n">error_log</span> <span class="o">/</span><span class="n">dev</span><span class="o">/</span><span class="n">null</span><span class="p">;</span>
  206. </pre></div>
  207. </div>
  208. <p>Restart service:</p>
  209. <div class="code sh highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">sudo</span> <span class="n">service</span> <span class="n">nginx</span> <span class="n">restart</span>
  210. </pre></div>
  211. </div>
  212. </div>
  213. </div>
  214. </div>
  215. <div class="section" id="with-apache">
  216. <h3><a class="toc-backref" href="#id10">with apache</a><a class="headerlink" href="#with-apache" title="Permalink to this headline">¶</a></h3>
  217. <p>Add wsgi mod:</p>
  218. <div class="code sh highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">sudo</span> <span class="n">apt</span><span class="o">-</span><span class="n">get</span> <span class="n">install</span> <span class="n">libapache2</span><span class="o">-</span><span class="n">mod</span><span class="o">-</span><span class="n">uwsgi</span>
  219. <span class="n">sudo</span> <span class="n">a2enmod</span> <span class="n">uwsgi</span>
  220. </pre></div>
  221. </div>
  222. <p>Add this configuration in the file /etc/apache2/apache2.conf:</p>
  223. <div class="code apache highlight-default notranslate"><div class="highlight"><pre><span></span><span class="o">&lt;</span><span class="n">Location</span> <span class="o">/&gt;</span>
  224. <span class="n">Options</span> <span class="n">FollowSymLinks</span> <span class="n">Indexes</span>
  225. <span class="n">SetHandler</span> <span class="n">uwsgi</span><span class="o">-</span><span class="n">handler</span>
  226. <span class="n">uWSGISocket</span> <span class="o">/</span><span class="n">run</span><span class="o">/</span><span class="n">uwsgi</span><span class="o">/</span><span class="n">app</span><span class="o">/</span><span class="n">searx</span><span class="o">/</span><span class="n">socket</span>
  227. <span class="o">&lt;/</span><span class="n">Location</span><span class="o">&gt;</span>
  228. </pre></div>
  229. </div>
  230. <p>Note that if your instance of searx is not at the root, you should
  231. change <code class="docutils literal notranslate"><span class="pre">&lt;Location</span> <span class="pre">/&gt;</span></code> by the location of your instance, like
  232. <code class="docutils literal notranslate"><span class="pre">&lt;Location</span> <span class="pre">/searx&gt;</span></code>.</p>
  233. <p>Restart Apache:</p>
  234. <div class="code sh highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">sudo</span> <span class="o">/</span><span class="n">etc</span><span class="o">/</span><span class="n">init</span><span class="o">.</span><span class="n">d</span><span class="o">/</span><span class="n">apache2</span> <span class="n">restart</span>
  235. </pre></div>
  236. </div>
  237. <div class="section" id="id2">
  238. <h4>disable logs<a class="headerlink" href="#id2" title="Permalink to this headline">¶</a></h4>
  239. <p>For better privacy you can disable Apache logs.</p>
  240. <p>WARNING: not tested</p>
  241. <p>WARNING: you can only disable logs for the whole (virtual) server not
  242. for a specific path.</p>
  243. <p>Go back to /etc/apache2/apache2.conf and above <code class="docutils literal notranslate"><span class="pre">&lt;Location</span> <span class="pre">/&gt;</span></code> add:</p>
  244. <div class="code apache highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">CustomLog</span> <span class="o">/</span><span class="n">dev</span><span class="o">/</span><span class="n">null</span> <span class="n">combined</span>
  245. </pre></div>
  246. </div>
  247. <p>Restart Apache:</p>
  248. <div class="code sh highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">sudo</span> <span class="o">/</span><span class="n">etc</span><span class="o">/</span><span class="n">init</span><span class="o">.</span><span class="n">d</span><span class="o">/</span><span class="n">apache2</span> <span class="n">restart</span>
  249. </pre></div>
  250. </div>
  251. </div>
  252. </div>
  253. </div>
  254. <div class="section" id="how-to-update">
  255. <h2><a class="toc-backref" href="#id11">How to update</a><a class="headerlink" href="#how-to-update" title="Permalink to this headline">¶</a></h2>
  256. <div class="code sh highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">cd</span> <span class="o">/</span><span class="n">usr</span><span class="o">/</span><span class="n">local</span><span class="o">/</span><span class="n">searx</span>
  257. <span class="n">sudo</span> <span class="o">-</span><span class="n">u</span> <span class="n">searx</span> <span class="o">-</span><span class="n">i</span>
  258. <span class="o">.</span> <span class="o">./</span><span class="n">searx</span><span class="o">-</span><span class="n">ve</span><span class="o">/</span><span class="nb">bin</span><span class="o">/</span><span class="n">activate</span>
  259. <span class="n">git</span> <span class="n">stash</span>
  260. <span class="n">git</span> <span class="n">pull</span> <span class="n">origin</span> <span class="n">master</span>
  261. <span class="n">git</span> <span class="n">stash</span> <span class="n">apply</span>
  262. <span class="o">./</span><span class="n">manage</span><span class="o">.</span><span class="n">sh</span> <span class="n">update_packages</span>
  263. <span class="n">sudo</span> <span class="n">service</span> <span class="n">uwsgi</span> <span class="n">restart</span>
  264. </pre></div>
  265. </div>
  266. </div>
  267. <div class="section" id="docker">
  268. <h2><a class="toc-backref" href="#id12">Docker</a><a class="headerlink" href="#docker" title="Permalink to this headline">¶</a></h2>
  269. <p>Make sure you have installed Docker. For instance, you can deploy searx like this:</p>
  270. <div class="code sh highlight-default notranslate"><div class="highlight"><pre><span></span>docker pull wonderfall/searx
  271. docker run -d --name searx -p $PORT:8888 wonderfall/searx
  272. </pre></div>
  273. </div>
  274. <p>Go to <a class="reference external" href="http://localhost:$PORT">http://localhost:$PORT</a>.</p>
  275. <p>See <a class="reference external" href="https://hub.docker.com/r/wonderfall/searx/">https://hub.docker.com/r/wonderfall/searx/</a> for more informations.</p>
  276. <p>It’s also possible to build searx from the embedded Dockerfile.</p>
  277. <div class="code sh highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">git</span> <span class="n">clone</span> <span class="n">https</span><span class="p">:</span><span class="o">//</span><span class="n">github</span><span class="o">.</span><span class="n">com</span><span class="o">/</span><span class="n">asciimoo</span><span class="o">/</span><span class="n">searx</span><span class="o">.</span><span class="n">git</span>
  278. <span class="n">cd</span> <span class="n">searx</span>
  279. <span class="n">docker</span> <span class="n">build</span> <span class="o">-</span><span class="n">t</span> <span class="n">whatever</span><span class="o">/</span><span class="n">searx</span> <span class="o">.</span>
  280. </pre></div>
  281. </div>
  282. </div>
  283. </div>
  284. <div class="section" id="references">
  285. <h1><a class="toc-backref" href="#id13">References</a><a class="headerlink" href="#references" title="Permalink to this headline">¶</a></h1>
  286. <blockquote>
  287. <div><ul class="simple">
  288. <li><a class="reference external" href="https://about.okhin.fr/posts/Searx/">https://about.okhin.fr/posts/Searx/</a> with some additions</li>
  289. <li>How to: <a class="reference external" href="https://www.reddit.com/r/privacytoolsIO/comments/366kvn/how_to_setup_your_own_privacy_respecting_search/">Setup searx in a couple of hours with a free SSL certificate</a></li>
  290. </ul>
  291. </div></blockquote>
  292. </div>
  293. </div>
  294. </div>
  295. </div>
  296. <div class="sphinxsidebar" role="navigation" aria-label="main navigation">
  297. <div class="sphinxsidebarwrapper">
  298. <h3><a href="../../index.html">Table Of Contents</a></h3>
  299. <ul>
  300. <li><a class="reference internal" href="#">Installation</a><ul>
  301. <li><a class="reference internal" href="#basic-installation">Basic installation</a></li>
  302. <li><a class="reference internal" href="#configuration">Configuration</a></li>
  303. <li><a class="reference internal" href="#check">Check</a></li>
  304. <li><a class="reference internal" href="#uwsgi">uwsgi</a></li>
  305. <li><a class="reference internal" href="#web-server">Web server</a><ul>
  306. <li><a class="reference internal" href="#with-nginx">with nginx</a><ul>
  307. <li><a class="reference internal" href="#hosted-at">Hosted at /</a></li>
  308. <li><a class="reference internal" href="#from-subdirectory-url-searx">from subdirectory URL (/searx)</a><ul>
  309. <li><a class="reference internal" href="#disable-logs">disable logs</a></li>
  310. </ul>
  311. </li>
  312. </ul>
  313. </li>
  314. <li><a class="reference internal" href="#with-apache">with apache</a><ul>
  315. <li><a class="reference internal" href="#id2">disable logs</a></li>
  316. </ul>
  317. </li>
  318. </ul>
  319. </li>
  320. <li><a class="reference internal" href="#how-to-update">How to update</a></li>
  321. <li><a class="reference internal" href="#docker">Docker</a></li>
  322. </ul>
  323. </li>
  324. <li><a class="reference internal" href="#references">References</a></li>
  325. </ul>
  326. <div class="sidebar_container body">
  327. <h1>Searx</h1>
  328. <ul>
  329. <li><a href="../../index.html">Home</a></li>
  330. <li><a href="https://github.com/asciimoo/searx">Source</a></li>
  331. <li><a href="../../blog/blog.html">Blog</a></li>
  332. <li><a href="https://github.com/asciimoo/searx/wiki">Wiki</a></li>
  333. <li><a href="https://github.com/asciimoo/searx/wiki/Searx-instances">Public instances</a></li>
  334. </ul>
  335. <hr />
  336. <ul>
  337. <li><a href="https://twitter.com/Searx_engine">Twitter</a></li>
  338. </ul>
  339. </div>
  340. <div role="note" aria-label="source link">
  341. <h3>This Page</h3>
  342. <ul class="this-page-menu">
  343. <li><a href="../../_sources/dev/install/installation.rst.txt"
  344. rel="nofollow">Show Source</a></li>
  345. </ul>
  346. </div>
  347. <div id="searchbox" style="display: none" role="search">
  348. <h3>Quick search</h3>
  349. <div class="searchformwrapper">
  350. <form class="search" action="../../search.html" method="get">
  351. <input type="text" name="q" />
  352. <input type="submit" value="Go" />
  353. <input type="hidden" name="check_keywords" value="yes" />
  354. <input type="hidden" name="area" value="default" />
  355. </form>
  356. </div>
  357. </div>
  358. <script type="text/javascript">$('#searchbox').show(0);</script>
  359. </div>
  360. </div>
  361. <div class="clearer"></div>
  362. </div>
  363. <div class="footer">
  364. &copy; Copyright 2015-2017, Adam Tauber.
  365. </div>
  366. </body>
  367. </html>