diff --git a/src/yunohost/hook.py b/src/yunohost/hook.py index 2a78f0801..b675caa2e 100644 --- a/src/yunohost/hook.py +++ b/src/yunohost/hook.py @@ -275,7 +275,7 @@ def hook_callback(action, hooks=[], args=None, no_trace=False, chdir=None, hook_args = pre_callback(name=name, priority=priority, path=path, args=args) hook_exec(path, args=hook_args, chdir=chdir, env=env, - no_trace=no_trace, raise_on_error=True) + no_trace=no_trace, raise_on_error=True, user="root") except MoulinetteError as e: state = 'failed' logger.error(e.strerror, exc_info=1)