TEST-13-NSPAWN: move container template to /usr/share
authorRichard Maw <richard.maw@codethink.co.uk>
Tue, 13 Feb 2024 12:50:58 +0000 (12:50 +0000)
committerDaan De Meyer <daan.j.demeyer@gmail.com>
Tue, 30 Apr 2024 16:17:13 +0000 (18:17 +0200)
Having directories in / causes problems for make-root-on-boot images

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

index 6dfb5277183b63ce3017aeee6c4e7ac905aa29d0..915f2db86bc7f67e3ffb760741c0d3b8454415ca 100755 (executable)
@@ -11,7 +11,7 @@ TEST_NO_NSPAWN=1
 
 test_append_files() {
     local workspace="${1:?}"
-    local container="$workspace/testsuite-13-container-template"
+    local container="$workspace/usr/share/testsuite-13-container-template"
 
     # For virtual wlan interface.
     instmods mac80211_hwsim
index 8eea263135b044b8007d47fdb92b80350bed4fa9..619cb8ebbfd625db8551503122478113065679d4 100755 (executable)
@@ -156,13 +156,13 @@ coverage_create_nspawn_dropin() {
 create_dummy_container() {
     local root="${1:?}"
 
-    if [[ ! -d /testsuite-13-container-template ]]; then
+    if [[ ! -d /usr/share/testsuite-13-container-template ]]; then
         echo >&2 "Missing container template, probably not running in TEST-13-NSPAWN?"
         exit 1
     fi
 
     mkdir -p "$root"
-    cp -a /testsuite-13-container-template/* "$root"
+    cp -a /usr/share/testsuite-13-container-template/* "$root"
     coverage_create_nspawn_dropin "$root"
 }