From 9e266ecad3cc20faf2c12cdab7862c29cf8df2ec Mon Sep 17 00:00:00 2001 From: Alexandre Flament Date: Sat, 2 Oct 2021 16:58:09 +0200 Subject: [PATCH] SearXNG: SEARX_BIND_ADDRESS --- CHANGELOG.rst | 2 +- docs/admin/engines/settings.rst | 2 +- docs/dev/makefile.rst | 2 +- utils/brand.env | 2 +- utils/build_env.py | 4 ++-- utils/filtron.sh | 2 +- utils/searx.sh | 2 +- 7 files changed, 8 insertions(+), 8 deletions(-) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index c319be8e9..c215f225e 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -360,7 +360,7 @@ News - Docker image updates - Bang expression fixes - Result merging fixes -- New environment variable added: SEARX_BIND_ADDRESS +- New environment variable added: SEARXNG_BIND_ADDRESS News diff --git a/docs/admin/engines/settings.rst b/docs/admin/engines/settings.rst index 0e1d0d710..8c23bb9bd 100644 --- a/docs/admin/engines/settings.rst +++ b/docs/admin/engines/settings.rst @@ -114,7 +114,7 @@ Global Settings If you change the value, don't forget to rebuild instance's environment (:ref:`utils/brand.env `) -``port`` & ``bind_address``: :ref:`buildenv SEARXNG_PORT & SEARX_BIND_ADDRESS ` +``port`` & ``bind_address``: :ref:`buildenv SEARXNG_PORT & SEARXNG_BIND_ADDRESS ` Port number and *bind address* of the SearXNG web application if you run it directly using ``python searx/webapp.py``. Doesn't apply to SearXNG running on Apache or Nginx. diff --git a/docs/dev/makefile.rst b/docs/dev/makefile.rst index 09e37502e..1db3ed703 100644 --- a/docs/dev/makefile.rst +++ b/docs/dev/makefile.rst @@ -109,7 +109,7 @@ from the YAML configuration: - ``SEARX_URL`` from :ref:`server.base_url ` (aka ``PUBLIC_URL``) -- ``SEARX_BIND_ADDRESS`` from :ref:`server.bind_address ` +- ``SEARXNG_BIND_ADDRESS`` from :ref:`server.bind_address ` - ``SEARXNG_PORT`` from :ref:`server.port ` .. _make run: diff --git a/utils/brand.env b/utils/brand.env index d63e686d4..5cc2af35b 100644 --- a/utils/brand.env +++ b/utils/brand.env @@ -1,5 +1,5 @@ export SEARX_URL='' export SEARXNG_PORT='8888' -export SEARX_BIND_ADDRESS='127.0.0.1' +export SEARXNG_BIND_ADDRESS='127.0.0.1' export GIT_URL='https://github.com/searxng/searxng' export GIT_BRANCH='master' diff --git a/utils/build_env.py b/utils/build_env.py index 750f29f1c..3ba4e4aaf 100644 --- a/utils/build_env.py +++ b/utils/build_env.py @@ -30,14 +30,14 @@ name_val = [ ('SEARX_URL' , 'server.base_url'), ('SEARXNG_PORT' , 'server.port'), - ('SEARX_BIND_ADDRESS' , 'server.bind_address'), + ('SEARXNG_BIND_ADDRESS' , 'server.bind_address'), ] brand_env = 'utils' + sep + 'brand.env' # Some defaults in the settings.yml are taken from the environment, -# e.g. SEARX_BIND_ADDRESS (:py:obj:`searx.settings_defaults.SHEMA`). When the +# e.g. SEARXNG_BIND_ADDRESS (:py:obj:`searx.settings_defaults.SHEMA`). When the # 'brand.env' file is created these enviroment variables should be unset first:: _unset = object() diff --git a/utils/filtron.sh b/utils/filtron.sh index bb2a8d742..a608f7769 100755 --- a/utils/filtron.sh +++ b/utils/filtron.sh @@ -28,7 +28,7 @@ FILTRON_LISTEN="${FILTRON_LISTEN:-127.0.0.1:4004}" # server.bind_address. The default of FILTRON_TARGET is taken from the YAML # configuration, do not change this value without reinstalling the entire # SearXNG suite including filtron & morty. -FILTRON_TARGET="${SEARX_BIND_ADDRESS}:${SEARXNG_PORT}" +FILTRON_TARGET="${SEARXNG_BIND_ADDRESS}:${SEARXNG_PORT}" SERVICE_NAME="filtron" SERVICE_USER="${SERVICE_USER:-${SERVICE_NAME}}" diff --git a/utils/searx.sh b/utils/searx.sh index d7838c5fc..ed33e18c8 100755 --- a/utils/searx.sh +++ b/utils/searx.sh @@ -12,7 +12,7 @@ source "${REPO_ROOT}/utils/lib_install.sh" # config # ---------------------------------------------------------------------------- -SEARX_INTERNAL_HTTP="${SEARX_BIND_ADDRESS}:${SEARXNG_PORT}" +SEARX_INTERNAL_HTTP="${SEARXNG_BIND_ADDRESS}:${SEARXNG_PORT}" SEARX_URL_PATH="${SEARX_URL_PATH:-$(echo "${PUBLIC_URL}" \ | sed -e 's,^.*://[^/]*\(/.*\),\1,g')}"