From e3d7b50bd91fa092a9d40be3ce016c330f9311ca Mon Sep 17 00:00:00 2001 From: marios Date: Wed, 13 Apr 2022 02:14:44 +0300 Subject: Root plugins (#35) * root plugins plugins can now specify if they want their methods to be ran as root. this is done via the multiprocess module. method calls are delegated to a separate process that is then down-privileged by default to user 1000, so the loader can safely be ran as root except it isn't really safe because the plugin is imported as root anyway * working implementation - follows the new plugin format with the plugin.json file - plugins are loaded in their own isolated process along with their own event loop and unix socket server for calling methods - private methods are now prepended with _ instead of __ * converted format to f-strings --- requirements.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'requirements.txt') diff --git a/requirements.txt b/requirements.txt index c77a53ed..579ebc0b 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,3 +1,4 @@ aiohttp==3.8.1 aiohttp-jinja2==1.5.0 -watchdog==2.1.7 \ No newline at end of file +watchdog==2.1.7 +multiprocess==0.70.12.2 \ No newline at end of file -- cgit v1.2.3