This helps to debug issues in remote CI.
Example logs (from the tests):
2022-11-27 16:34:46 326 [2767]: Running in unprivileged mode uid=1001 gid=1001
Signed-off-by: Nir Soffer <nsoffer(a)redhat.com>
---
src/main.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/main.c b/src/main.c
index a9ceee5..f0182b6 100644
--- a/src/main.c
+++ b/src/main.c
@@ -1755,21 +1755,22 @@ static int do_daemon(void)
return rv;
strcpy(client[helper_ci].owner_name, "helper");
setup_signals();
setup_logging();
if (strcmp(run_dir, DEFAULT_RUN_DIR))
log_warn("Using non-standard run directory '%s'", run_dir);
if (!privileged)
- log_warn("Running in unprivileged mode");
+ log_warn("Running in unprivileged mode uid=%d gid=%d",
+ com.uid, com.gid);
/* If we run as root, make run_dir owned by root, so we can create the
* lockfile when selinux disables DAC_OVERRIDE.
* See
https://danwalsh.livejournal.com/79643.html */
fd = lockfile(run_dir, SANLK_LOCKFILE_NAME, com.uid,
privileged ? 0 : com.gid);
if (fd < 0) {
close_logging();
return fd;
--
2.38.1