diff options
author | Yumei Huang <yuhuang@redhat.com> | 2025-09-26 09:17:14 +0800 |
---|---|---|
committer | Stefano Brivio <sbrivio@redhat.com> | 2025-09-26 12:13:57 +0200 |
commit | f07d7b0c2a90f5888f1f4931274956867b10c793 (patch) | |
tree | 02d4a9685571c3b7eb3f10d1f1927c1064d0a783 | |
parent | e81c692e460ad3d0b717eeea8e7c16d93ea207fe (diff) | |
download | passt-f07d7b0c2a90f5888f1f4931274956867b10c793.tar passt-f07d7b0c2a90f5888f1f4931274956867b10c793.tar.gz passt-f07d7b0c2a90f5888f1f4931274956867b10c793.tar.bz2 passt-f07d7b0c2a90f5888f1f4931274956867b10c793.tar.lz passt-f07d7b0c2a90f5888f1f4931274956867b10c793.tar.xz passt-f07d7b0c2a90f5888f1f4931274956867b10c793.tar.zst passt-f07d7b0c2a90f5888f1f4931274956867b10c793.zip |
test: fix 'make assets' failure as root
Running `make assets` under `test` as root fails with a "Permission denied"
error when `prepare-distro-img.sh` invokes `virt-edit` and `guestfish`. This
is due to a known bug in libvirt.
Work around the issue by switching to the direct backend.
Signed-off-by: Yumei Huang <yuhuang@redhat.com>
Reviewed-by: Richard W.M. Jones <rjones@redhat.com>
Signed-off-by: Stefano Brivio <sbrivio@redhat.com>
-rwxr-xr-x | test/prepare-distro-img.sh | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/test/prepare-distro-img.sh b/test/prepare-distro-img.sh index 0d967c9..be2386e 100755 --- a/test/prepare-distro-img.sh +++ b/test/prepare-distro-img.sh @@ -3,6 +3,10 @@ IMG="$1" PASST_FILES="$(echo ../*.c ../*.h ../*.sh ../*.1 ../Makefile ../README.md)" +# This is just a workaround for Fedora and related distributions. +# Once it gets fixed, we can drop this. +export LIBGUESTFS_BACKEND=direct + virt-edit -a $IMG /lib/systemd/system/serial-getty@.service -e 's/ExecStart=.*/ExecStart=\/sbin\/agetty --autologin root -8 --keep-baud 115200,38400,9600 %I $TERM/g' guestfish --rw -a $IMG -i <<EOF |