searx/admin/installation-docker.html

179 lines
8.7 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!DOCTYPE html>
<html lang="en">
<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>Docker installation &#8212; Searx Documentation (Searx-1.1.0.tex)</title>
<link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
<link rel="stylesheet" type="text/css" href="../_static/searx.css" />
<link rel="stylesheet" type="text/css" href="../_static/tabs.css" />
<script data-url_root="../" id="documentation_options" src="../_static/documentation_options.js"></script>
<script src="../_static/jquery.js"></script>
<script src="../_static/underscore.js"></script>
<script src="../_static/_sphinx_javascript_frameworks_compat.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="next" title="How to update" href="update-searx.html" />
<link rel="prev" title="Install with apache" href="installation-apache.html" />
</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="update-searx.html" title="How to update"
accesskey="N">next</a> |</li>
<li class="right" >
<a href="installation-apache.html" title="Install with apache"
accesskey="P">previous</a> |</li>
<li class="nav-item nav-item-0"><a href="../index.html">Searx Documentation (Searx-1.1.0.tex)</a> &#187;</li>
<li class="nav-item nav-item-1"><a href="index.html" accesskey="U">Administrator documentation</a> &#187;</li>
<li class="nav-item nav-item-this"><a href="">Docker installation</a></li>
</ul>
</div>
<div class="document">
<div class="documentwrapper">
<div class="bodywrapper">
<div class="body" role="main">
<section id="docker-installation">
<span id="installation-docker"></span><h1>Docker installation<a class="headerlink" href="#docker-installation" title="Permalink to this heading"></a></h1>
<nav class="contents local" id="contents">
<p class="topic-title">Contents</p>
<ul class="simple">
<li><p><a class="reference internal" href="#docker-image-searx-searx" id="id1">Docker image searx/searx</a></p>
<ul>
<li><p><a class="reference internal" href="#command-line" id="id2">Command line</a></p></li>
<li><p><a class="reference internal" href="#build-the-image" id="id3">Build the image</a></p></li>
</ul>
</li>
<li><p><a class="reference internal" href="#public-instance" id="id4">Public instance</a></p></li>
</ul>
</nav>
<hr class="docutils" />
<section id="docker-image-searx-searx">
<h2><a class="toc-backref" href="#id1" role="doc-backlink">Docker image searx/searx</a><a class="headerlink" href="#docker-image-searx-searx" title="Permalink to this heading"></a></h2>
<p>The docker image is <a class="reference external" href="https://hub.docker.com/r/searx/searx">searx/searx</a> (based on <a class="reference external" href="https://github.com/searx/searx">github.com/searx/searx</a>).</p>
<p>Make sure you have <a class="reference external" href="https://docs.docker.com/get-docker/">installed Docker</a>. For instance, you can deploy a local instance:</p>
<div class="highlight-sh notranslate"><div class="highlight"><pre><span></span><span class="nb">export</span> <span class="nv">PORT</span><span class="o">=</span><span class="m">80</span>
docker pull searx/searx
docker run --rm -d -v <span class="si">${</span><span class="nv">PWD</span><span class="si">}</span>/searx:/etc/searx -p <span class="nv">$PORT</span>:8080 -e <span class="nv">BASE_URL</span><span class="o">=</span>http://localhost:<span class="nv">$PORT</span>/ searx/searx
</pre></div>
</div>
<p>Go to <code class="docutils literal notranslate"><span class="pre">http://localhost:$PORT</span></code>.</p>
<p>Inside <code class="docutils literal notranslate"><span class="pre">${PWD}/searx</span></code>, you will find <code class="docutils literal notranslate"><span class="pre">settings.yml</span></code> and <code class="docutils literal notranslate"><span class="pre">uwsgi.ini</span></code>.
You can modify these files according to your needs and restart the Docker image.</p>
<section id="command-line">
<h3><a class="toc-backref" href="#id2" role="doc-backlink">Command line</a><a class="headerlink" href="#command-line" title="Permalink to this heading"></a></h3>
<div class="highlight-sh notranslate"><div class="highlight"><pre><span></span>docker run --rm -it searx/searx -h
</pre></div>
</div>
<div class="highlight-text notranslate"><div class="highlight"><pre><span></span>Command line:
-h Display this help
-d Dry run to update the configuration files.
-f Always update on the configuration files (existing files are renamed with the .old suffix)
Without this option, the new configuration files are copied with the .new suffix
Environment variables:
INSTANCE_NAME settings.yml : general.instance_name
AUTOCOMPLETE settings.yml : search.autocomplete
BASE_URL settings.yml : server.base_url
MORTY_URL settings.yml : result_proxy.url
MORTY_KEY settings.yml : result_proxy.key
BIND_ADDRESS uwsgi bind to the specified TCP socket using HTTP protocol. Default value: &quot;0.0.0.0:8080&quot;
Volume:
/etc/searx the docker entry point copies settings.yml and uwsgi.ini in this directory (see the -f command line option)
</pre></div>
</div>
</section>
<section id="build-the-image">
<h3><a class="toc-backref" href="#id3" role="doc-backlink">Build the image</a><a class="headerlink" href="#build-the-image" title="Permalink to this heading"></a></h3>
<p>Its also possible to build searx from the embedded Dockerfile.</p>
<div class="highlight-sh notranslate"><div class="highlight"><pre><span></span>git clone https://github.com/searx/searx.git
<span class="nb">cd</span> searx
make docker.build
</pre></div>
</div>
</section>
</section>
<section id="public-instance">
<h2><a class="toc-backref" href="#id4" role="doc-backlink">Public instance</a><a class="headerlink" href="#public-instance" title="Permalink to this heading"></a></h2>
<p>If you intend to create a public instance using Docker, see <a class="reference external" href="https://github.com/searx/searx-docker">https://github.com/searx/searx-docker</a></p>
</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://searx.github.io/searx/blog/index.html">Blog</a>
<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://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">Administrator documentation</a>
<ul>
<li>Previous: <a href="installation-apache.html" title="previous chapter">Install with apache</a>
<li>Next: <a href="update-searx.html" title="next chapter">How to update</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" autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"/>
<input type="submit" value="Go" />
</form>
</div>
</div>
<script>document.getElementById('searchbox').style.display = "block"</script>
</div>
</div>
<div class="clearer"></div>
</div>
<div class="footer" role="contentinfo">
&#169; Copyright 2015-2022, Adam Tauber, Noémi Ványi.
Created using <a href="https://www.sphinx-doc.org/">Sphinx</a> 5.1.1.
</div>
<script src="../_static/version_warning_offset.js"></script>
</body>
</html>