From 4735aa8fd6242aa37d06f11470c3583a0a261f87 Mon Sep 17 00:00:00 2001 From: Antonin Godard Date: Mon, 13 Oct 2025 09:12:55 +0200 Subject: [PATCH] tools/build-docs-container: use the basename of OCI to append args What we have is OCI = $(which $CONTAINERCMD) = /usr/bin/{docker,podman}. So we never pass the current if conditions. Compare against the basename of OCI to pass the checks. Reviewed-by: Quentin Schulz (From yocto-docs rev: 41fc95a0e06fec29cdd8c47f75093f0a6a2df8c0) Signed-off-by: Antonin Godard Signed-off-by: Richard Purdie --- documentation/tools/build-docs-container | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/documentation/tools/build-docs-container b/documentation/tools/build-docs-container index 26ea1d2e2a..f97cfc4025 100755 --- a/documentation/tools/build-docs-container +++ b/documentation/tools/build-docs-container @@ -154,11 +154,11 @@ main () --security-opt label=disable ) - if [ "$OCI" = "docker" ]; then + if [ "$(basename "$OCI")" = "docker" ]; then args_run+=( --user="$(id -u)":"$(id -g)" ) - elif [ "$OCI" = "podman" ]; then + elif [ "$(basename "$OCI")" = "podman" ]; then # we need net access to fetch bitbake terms args_run+=( --cap-add=NET_RAW