mirror of
https://github.com/searxng/searxng.git
synced 2025-08-28 14:29:05 +02:00
SearXNG: environment variables
This commit is contained in:
parent
e39a03cc61
commit
430babca25
9 changed files with 47 additions and 25 deletions
|
@ -35,12 +35,12 @@ def get_default_settings_path():
|
|||
|
||||
def get_user_settings_path():
|
||||
# find location of settings.yml
|
||||
if 'SEARX_SETTINGS_PATH' in environ:
|
||||
if 'SEARXNG_SETTINGS_PATH' in environ:
|
||||
# if possible set path to settings using the
|
||||
# enviroment variable SEARX_SETTINGS_PATH
|
||||
return check_settings_yml(environ['SEARX_SETTINGS_PATH'])
|
||||
# enviroment variable SEARXNG_SETTINGS_PATH
|
||||
return check_settings_yml(environ['SEARXNG_SETTINGS_PATH'])
|
||||
|
||||
if environ.get('SEARX_DISABLE_ETC_SETTINGS', '').lower() in ('1', 'true'):
|
||||
if environ.get('SEARXNG_DISABLE_ETC_SETTINGS', '').lower() in ('1', 'true'):
|
||||
return None
|
||||
|
||||
# if not, get it from searx code base or last solution from /etc/searx
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue