21 lines
449 B
Bash
Executable File
21 lines
449 B
Bash
Executable File
#!/bin/bash -e
|
|
cd "$(dirname "$0")"
|
|
. ../lib.sh
|
|
|
|
hda='https://geo.mirror.pkgbuild.com/images/latest/Arch-Linux-x86_64-basic.qcow2'
|
|
|
|
if ! [ -f hda.qcow2 ]; then
|
|
ask_yn "hda does not exist. Download?" \
|
|
&& curl -LC- -o hda.qcow2 "$hda" \
|
|
|| exit 1
|
|
fi
|
|
|
|
CMD=(
|
|
"${CMD[@]}"
|
|
-nic user,model=virtio-net-pci
|
|
# USB passthrough, might need root privileges
|
|
#-device usb-host,vendorid=0xffff,productid=0xffff
|
|
)
|
|
|
|
"${CMD[@]}"
|