]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
TEST-13-NSPAWN: explicitly create usr/lib/systemd directory in the container image
authorYu Watanabe <watanabe.yu+github@gmail.com>
Thu, 4 Jun 2026 04:53:47 +0000 (13:53 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Thu, 4 Jun 2026 19:56:34 +0000 (04:56 +0900)
The main systemd package is not installed in the minimal image,
hence the directory may not exist.

test/units/TEST-13-NSPAWN.nspawn.sh

index a6f5b32f6268f3479f00266f46683ae8f3ef5222..50282709285db5f472fb12d2f97225b22c186c37 100755 (executable)
@@ -1586,6 +1586,7 @@ testcase_boot_param_split() {
     # Replace the init binary with a stub that records the argv and environment nspawn passes to it,
     # so we can verify that kernel-cmdline-style KEY=VALUE arguments are split between PID 1's
     # environment and argv the same way the kernel splits them.
+    mkdir -p "$root/usr/lib/systemd"
     cat >"$root/usr/lib/systemd/systemd" <<'EOF'
 #!/bin/bash
 set -e