Browse Source

build/boot: "we can be errors, just for one day"

pull/191/head 20.1.9
Franco Fichtner 3 months ago
parent
commit
35d1e1138f
1 changed files with 13 additions and 3 deletions
  1. +13
    -3
      build/boot.sh

+ 13
- 3
build/boot.sh View File

@ -33,19 +33,29 @@ SELF=boot
if [ -z "${1}" ]; then
echo ">> No image given."
exit 0
exit 1
fi
IMAGE=$(find ${IMAGESDIR} -name "*-${1}-${PRODUCT_ARCH}.*")
if [ ! -f "${IMAGE}" ]; then
echo ">> No image found."
exit 1
fi
echo ">>> Booting image ${IMAGE}..."
ifconfig tap create # XXX requires tap0 to be created now
TAPDEV=tap0
if ! ifconfig ${TAPDEV}; then
TAPDEV=$(ifconfig tap create)
fi
kldstat -qm vmm || kldload vmm
bhyveload -m 1024 -d ${IMAGE} vm0
bhyve -c 1 -m 1024 -AHP \
-s 0:0,hostbridge \
-s 1:0,virtio-net,tap0 \
-s 1:0,virtio-net,${TAPDEV} \
-s 2:0,ahci-hd,${IMAGE} \
-s 31,lpc -l com1,stdio \
vm0 || true

Loading…
Cancel
Save