Skip to content

Commit

Permalink
Fix import script
Browse files Browse the repository at this point in the history
  • Loading branch information
mekanix committed Nov 26, 2019
1 parent 757ab72 commit 435e7cc
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions scripts/import.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,13 @@ fi

IMAGE=`basename ${IMAGE_PATH}`
JAIL=`echo ${IMAGE} | sed 's;\.img$;;'`

trap "rm -rf ${CBSD_WORKDIR}/import/${IMAGE}" HUP INT ABRT BUS TERM EXIT

cp "${IMAGE_PATH}" "${CBSD_WORKDIR}/import/${IMAGE}"
if [ "${HYPERVISOR}" = "jail" ]; then
echo cbsd jimport "${IMAGE}"
cbsd jimport "${IMAGE}"
cbsd jimport "${JAIL}"
cbsd jset jname=${JAIL} host_hostname=${JAIL}.${DOMAIN}
else
echo cbsd bimport "${IMAGE}"
cbsd bimport "${JAIL}"
fi

0 comments on commit 435e7cc

Please sign in to comment.