if DOCKER_RUNNING in environment add LOG_PERROR to openlog

addresses https://github.com/owntracks/recorder/issues/426
This commit is contained in:
Jan-Piet Mens
2023-10-24 11:00:32 +02:00
parent f0da7cde30
commit 95adafc90f
+1 -1
View File
@@ -1514,7 +1514,7 @@ int main(int argc, char **argv)
udata.debug = FALSE;
flags = LOG_PID;
if (isatty(0)) {
if (isatty(0) || (getenv("DOCKER_RUNNING") != NULL)) {
flags |= LOG_PERROR;
}
openlog("ot-recorder", flags, syslog_facility_code(logfacility));