From 26a7ab8f4887dd227ccd2ba3be49faa35ab72559 Mon Sep 17 00:00:00 2001 From: Claudius Heine Date: Mon, 19 Sep 2022 15:53:17 +0200 Subject: [PATCH] kas-container: add --log-driver=none as default runtime arg Container engines per default log all container output into journald (Podman) or a json file (Docker). A build with kas-container/bitbake containes lots of useless build output like progress lines, etc. In case of Podman, where journald is used, this means that all this is spammed into the journald buffer and possible also send to ttys or even serial ttys. This might make sense for containers that output only status information about running services, but for a build process, this is mostly just spamming and causes important information to be lost. Since the stdout/stderr output of the container is used for kas-container ordinarily, the background logging from the container image can be deactivated. Therefor add the `--log-driver=none` parameter to all container runtimes command lines. Signed-off-by: Claudius Heine Signed-off-by: Jan Kiszka --- kas-container | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/kas-container b/kas-container index 5b2871d..239630e 100755 --- a/kas-container +++ b/kas-container @@ -161,13 +161,15 @@ if [ -z "${KAS_CONTAINER_ENGINE}" ]; then fi fi +KAS_RUNTIME_ARGS="--log-driver=none" + case "${KAS_CONTAINER_ENGINE}" in docker) KAS_CONTAINER_COMMAND="docker" ;; podman) KAS_CONTAINER_COMMAND="podman" - KAS_RUNTIME_ARGS="--security-opt label=disable" + KAS_RUNTIME_ARGS="${KAS_RUNTIME_ARGS} --security-opt label=disable" ;; *) echo "$0: unknown container engine '${KAS_CONTAINER_ENGINE}'" >&2