MT#57453 vagrant_configuration: remove fake systemd presence after execution

Let's restore system state of /run/systemd/system for
VBoxLinuxAdditions, to avoid any unexpected side effects.

Followup for git rev 8601193

Change-Id: I632c7d60ebb627c3a80d4c1f9b264d6d0a13b4f1
mr11.5
Michael Prokop 2 years ago
parent 561303359e
commit 793a93bc43

@ -1099,10 +1099,12 @@ vagrant_configuration() {
FAKE_UNAME='/tmp/fake-uname.so'
fi
# if ! [ -d "${TARGET}/run/systemd/system" ] ; then
local vbox_systemd_workaround=false
if ! [ -d "${TARGET}/run/systemd/system" ] ; then
echo "Creating /run/systemd/system for systemd detection within VBoxLinuxAdditions"
mkdir -p "${TARGET}/run/systemd/system"
# fi
vbox_systemd_workaround=true
fi
grml-chroot "${TARGET}" env \
UTS_RELEASE="${KERNELVERSION}" LD_PRELOAD="${FAKE_UNAME}" \
@ -1110,6 +1112,11 @@ vagrant_configuration() {
tail -10 "${TARGET}/var/log/vboxadd-install.log"
umount "${TARGET}/media/cdrom/"
if "${vbox_systemd_workaround}" ; then
echo "Removing /run/systemd/system workaround for VBoxLinuxAdditions again"
rmdir "${TARGET}/run/systemd/system" || true
fi
# VBoxLinuxAdditions.run chooses /usr/lib64 as soon as this directory exists, which
# is the case for our PRO systems shipping the heartbeat-2 package; then the
# symlink /sbin/mount.vboxsf points to the non-existing /usr/lib64/VBoxGuestAdditions/mount.vboxsf

Loading…
Cancel
Save