echo "Boot device will be $dev_boot" &&
fs=ext4
fi &&
- dev_swap="/dev/mapper/$vg-$guest--swap" &&
+ if [ "$vg" != "" ]; then
+ dev_swap="/dev/mapper/$vg-$guest--swap"
+ elif [ -d /SWAPFILES ]; then
+ dev_swap=/SWAPFILES/$guest-swap
+ else
+ echo "No idea how to do swap" && false
+ fi &&
echo -n "Use a /boot filesystem (strongly recommended)? [Y/n] " &&
read use_boot &&
echo "Swap device will be $dev_swap" &&
chroot . passwd
}}}
+Set a nameserver config that works once the VM has booted. Later in the process we will install unbound anyway.
+{{{
+cat > etc/resolv.conf << EOF
+nameserver 8.8.8.8
+search debian.org
+EOF
+}}}
+
And unmount:
{{{
=== virsh setup ===
-Setup a new kvm domain by creating a new file in /etc/da-virt/`hostname/$guest.xml.
+Setup a new kvm domain by creating a new file in /etc/dsa-kvm/`hostname/$guest.xml.
* Properly configure hostname
* Pick a new uuid ({{{uuidgen}}})