[enh] run hooks as root

This commit is contained in:
Laurent Peuch 2017-03-05 16:33:17 +01:00
parent e1a5074c75
commit 76a7a36c62

View file

@ -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)