Merge remote-tracking branch 'origin/main' into version-updates
This commit is contained in:
@@ -2,6 +2,12 @@
|
|||||||
set -ex
|
set -ex
|
||||||
|
|
||||||
#disk="${1}"
|
#disk="${1}"
|
||||||
|
# Do host-specific things
|
||||||
|
virt="${2}"
|
||||||
|
# Values I've found so far
|
||||||
|
# "microsoft" == Hyper-V
|
||||||
|
# "oracle" == VirtualBox
|
||||||
|
# "KVM" == KVM/Qemu
|
||||||
|
|
||||||
# Set locale info to reasonable defaults
|
# Set locale info to reasonable defaults
|
||||||
ln -sf /usr/share/zoneinfo/UTC /etc/localtime
|
ln -sf /usr/share/zoneinfo/UTC /etc/localtime
|
||||||
@@ -37,14 +43,9 @@ useradd vagrant -g vagrant -G wheel -m
|
|||||||
[ -d /home/vagrant ] || exit 1
|
[ -d /home/vagrant ] || exit 1
|
||||||
echo "vagrant:vagrant" | chpasswd
|
echo "vagrant:vagrant" | chpasswd
|
||||||
|
|
||||||
# Do host-specific things
|
|
||||||
virt="$(systemd-detect-virt)"
|
|
||||||
# Values I've found so far
|
|
||||||
# "microsoft" == Hyper-V
|
|
||||||
# "oracle" == VirtualBox
|
|
||||||
# "KVM" == KVM/Qemu
|
|
||||||
if [ "${virt}" == "microsoft" ]; then
|
if [ "${virt}" == "microsoft" ]; then
|
||||||
pacman -S --noconfirm hyperv
|
pacman -S --noconfirm hyperv
|
||||||
systemctl enable hv_kvp_daemon
|
systemctl enable hv_kvp_daemon
|
||||||
systemctl enable hv_vss_daemon
|
systemctl enable hv_vss_daemon
|
||||||
fi
|
fi
|
||||||
|
sleep 60
|
||||||
|
|||||||
@@ -47,7 +47,7 @@ cat /mnt/etc/fstab
|
|||||||
|
|
||||||
# Run stuff in the chroot
|
# Run stuff in the chroot
|
||||||
curl -o /mnt/in-chroot.sh "http://${host}:${port}/in-chroot.sh"
|
curl -o /mnt/in-chroot.sh "http://${host}:${port}/in-chroot.sh"
|
||||||
arch-chroot /mnt /usr/bin/bash /in-chroot.sh "${disk}"
|
arch-chroot /mnt /usr/bin/bash /in-chroot.sh "${disk}" "$(systemd-detect-virt)"
|
||||||
rm /mnt/in-chroot.sh
|
rm /mnt/in-chroot.sh
|
||||||
|
|
||||||
reboot
|
reboot
|
||||||
|
|||||||
Reference in New Issue
Block a user