diff --git a/searx/plugins/__init__.py b/searx/plugins/__init__.py index 6c1bea8d0..98117dd28 100644 --- a/searx/plugins/__init__.py +++ b/searx/plugins/__init__.py @@ -226,7 +226,10 @@ def plugin_module_names(): def initialize(app): + # it is possible to block plugins from being registered into plugin chain + blocked_plugins = settings['outgoing'].get('blocked_plugins', []) + for module_name, external in plugin_module_names(): plugin = load_and_initialize_plugin(module_name, external, (app, settings)) - if plugin: + if plugin and plugin.name not in blocked_plugins: plugins.register(plugin) diff --git a/searx/settings.yml b/searx/settings.yml index 0ea69007a..a9f96e9ca 100644 --- a/searx/settings.yml +++ b/searx/settings.yml @@ -157,6 +157,12 @@ outgoing: # - plugin2 # - ... +# Plugins listed here will be loaded, but will not be registered into plugins chain. +# The engine will not use them to process queries. +# +# blocked_plugins: +# - 'Self Informations' + # Comment or un-comment plugin to activate / deactivate by default. # # enabled_plugins: