mirror of
git://github.com/lxc/lxc
synced 2025-09-03 07:29:47 +00:00
Disable logpath for unprivileged containers
Signed-off-by: Stéphane Graber <stgraber@ubuntu.com> Acked-by: Serge E. Hallyn <serge.hallyn@ubuntu.com>
This commit is contained in:
@@ -318,6 +318,11 @@ extern int lxc_log_init(const char *name, const char *file,
|
|||||||
lxc_logfile_specified = 1;
|
lxc_logfile_specified = 1;
|
||||||
ret = __lxc_log_set_file(file, 1);
|
ret = __lxc_log_set_file(file, 1);
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
|
/* For now, unprivileged containers have to set -l to get logging */
|
||||||
|
if (geteuid())
|
||||||
|
return 0;
|
||||||
|
|
||||||
ret = -1;
|
ret = -1;
|
||||||
|
|
||||||
if (!lxcpath)
|
if (!lxcpath)
|
||||||
|
Reference in New Issue
Block a user