conf: Don't lecture user about starting us as root
libguestfs tools have a good reason to run as root: if the guest image is owned by root, it would be counterproductive to encourage users to invoke them as non-root, as it would require changing permissions or ownership of the image file. And if they run as root, we'll start as root, too. Warn users we'll switch to 'nobody', but don't tell them what to do. Reported-by: Richard W.M. Jones <rjones@redhat.com> Signed-off-by: Stefano Brivio <sbrivio@redhat.com> Reviewed-by: David Gibson <david@gibson.dropbear.id.au> Reviewed-by: Richard W.M. Jones <rjones@redhat.com>
This commit is contained in:
parent
3f917b326b
commit
45b8632dcc
1 changed files with 1 additions and 1 deletions
2
conf.c
2
conf.c
|
@ -1093,7 +1093,7 @@ static void conf_ugid(char *runas, uid_t *uid, gid_t *gid)
|
|||
return;
|
||||
|
||||
/* ...otherwise use nobody:nobody */
|
||||
warn("Don't run as root. Changing to nobody...");
|
||||
warn("Started as root. Changing to nobody...");
|
||||
{
|
||||
#ifndef GLIBC_NO_STATIC_NSS
|
||||
const struct passwd *pw;
|
||||
|
|
Loading…
Reference in a new issue