13Step by step installation for Debian/Ubuntu with virtualenv. For Ubuntu, be sure
14to have enable universe repository.
20 $ sudo -H apt-get install \
21 git build-essential libxslt-dev \
22 python-dev python-virtualenv python-babel \
23 zlib1g-dev libffi-dev libssl-dev
30 sudo -H git clone https://github.com/asciimoo/searx.git
31 sudo -H useradd searx -d /usr/local/searx
32 sudo -H chown searx:searx -R /usr/local/searx
34Install dependencies in a virtualenv:
43 (searx)$ virtualenv searx-ve
44 (searx)$ . ./searx-ve/bin/activate
45 (searx)$ ./manage.sh update_packages
52 sed -i -e "s/ultrasecretkey/`openssl rand -hex 16`/g" searx/settings.yml
54Edit searx/settings.yml if necessary.
63 python searx/webapp.py
65Go to http://localhost:8888
67If everything works fine, disable the debug option in settings.yml:
71 sed -i -e "s/debug : True/debug : False/g" searx/settings.yml
73At this point searx is not demonized ; uwsgi allows this.
75You can exit the virtualenv and the searx user bash (enter exit command
85 sudo -H apt-get install \
86 uwsgi uwsgi-plugin-python
88Create the configuration file ``/etc/uwsgi/apps-available/searx.ini`` with this
94 # Who will run the code
98 # disable logging for privacy
99 disable-logging = true
101 # Number of workers (usually CPU count)
104 # The right granted on the created socket
107 # Plugin to use and interpretor config
108 single-interpreter = true
112 enable-threads = true
115 module = searx.webapp
117 # Support running the module from a webserver subdirectory.
118 route-run = fixpathinfo:
120 # Virtualenv and python path
121 virtualenv = /usr/local/searx/searx-ve/
122 pythonpath = /usr/local/searx/
123 chdir = /usr/local/searx/searx/
125Activate the uwsgi application and restart:
129 cd /etc/uwsgi/apps-enabled
130 ln -s ../apps-available/searx.ini
131 /etc/init.d/uwsgi restart
139If nginx is not installed (uwsgi will not work with the package
144 sudo -H apt-get install nginx
149Create the configuration file ``/etc/nginx/sites-available/searx`` with this
156 server_name searx.example.com;
157 root /usr/local/searx/searx;
163 include uwsgi_params;
164 uwsgi_pass unix:/run/uwsgi/app/searx/socket;
168Create a symlink to sites-enabled:
172 sudo -H ln -s /etc/nginx/sites-available/searx /etc/nginx/sites-enabled/searx
178 sudo -H service nginx restart
179 sudo -H service uwsgi restart
181from subdirectory URL (/searx)
182~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
184Add this configuration in the server config file
185``/etc/nginx/sites-enabled/default``:
189 location /searx/static {
190 alias /usr/local/searx/searx/static;
194 uwsgi_param SCRIPT_NAME /searx;
195 include uwsgi_params;
196 uwsgi_pass unix:/run/uwsgi/app/searx/socket;
200**OR** using reverse proxy (Please, note that reverse proxy advised to be used
201in case of single-user or low-traffic instances.)
205 location /searx/static {
206 alias /usr/local/searx/searx/static;
210 proxy_pass http://127.0.0.1:8888;
211 proxy_set_header Host $host;
212 proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
213 proxy_set_header X-Scheme $scheme;
214 proxy_set_header X-Script-Name /searx;
219Enable ``base_url`` in ``searx/settings.yml``
223 base_url : http://your.domain.tld/searx/
229 sudo -H service nginx restart
230 sudo -H service uwsgi restart
235for better privacy you can disable nginx logs about searx.
237how to proceed: below ``uwsgi_pass`` in ``/etc/nginx/sites-available/default``
242 access_log /dev/null;
249 sudo -H service nginx restart
258 sudo -H apt-get install libapache2-mod-uwsgi
259 sudo -H a2enmod uwsgi
261Add this configuration in the file ``/etc/apache2/apache2.conf``:
266 Options FollowSymLinks Indexes
267 SetHandler uwsgi-handler
268 uWSGISocket /run/uwsgi/app/searx/socket
271Note that if your instance of searx is not at the root, you should change
272``<Location />`` by the location of your instance, like ``<Location /searx>``.
278 sudo -H /etc/init.d/apache2 restart
283For better privacy you can disable Apache logs.
287 You can only disable logs for the whole (virtual) server not for a specific
290Go back to ``/etc/apache2/apache2.conf`` and above ``<Location />`` add:
294 CustomLog /dev/null combined
300 sudo -H /etc/init.d/apache2 restart
312 (searx)$ . ./searx-ve/bin/activate
314 (searx)$ git pull origin master
315 (searx)$ git stash apply
316 (searx)$ ./manage.sh update_packages
320 sudo -H service uwsgi restart
325Make sure you have installed Docker. For instance, you can deploy searx like this:
329 docker pull wonderfall/searx
330 docker run -d --name searx -p $PORT:8888 wonderfall/searx
332Go to ``http://localhost:$PORT``.
334See https://hub.docker.com/r/wonderfall/searx/ for more informations. It's also
335possible to build searx from the embedded Dockerfile.
339 git clone https://github.com/asciimoo/searx.git
341 docker build -t whatever/searx .
346* https://about.okhin.fr/posts/Searx/ with some additions
348* How to: `Setup searx in a couple of hours with a free SSL certificate
349 <https://www.reddit.com/r/privacytoolsIO/comments/366kvn/how_to_setup_your_own_privacy_respecting_search/>`__
keysesc to close
- j k
- move down, up
- enter
- open
- esc
- back, or up a level
- 1 2 3 4
- readme, files, commits, refs
- /
- filter
- y
- copy the clone command
- c
- compare the chosen commit with another (or shift-click both)
- ?
- show or hide this list