$TOOLBOX_DOCKER_ARCHIVE variable removed

pull/3607/head
Kauê Doretto Grecchi 2019-01-30 14:37:17 -02:00
parent 4226ff70aa
commit d609aa3239
1 changed files with 0 additions and 8 deletions

View File

@ -53,14 +53,6 @@ if [ ! -f "${osrelease}" ] || systemctl is-failed -q "${machinename}" ; then
riid=$(sudo --preserve-env rkt --insecure-options=image fetch "docker://${TOOLBOX_DOCKER_IMAGE}:${TOOLBOX_DOCKER_TAG}")
sudo --preserve-env rkt image extract --overwrite --rootfs-only "${riid}" "${machinepath}"
sudo --preserve-env rkt image rm "${riid}"
elif [[ -n "${TOOLBOX_DOCKER_ARCHIVE}" ]]; then
tmpdir=$(mktemp -d -p /var/tmp/)
trap "sudo rm -rf ${tmpdir}" EXIT PIPE
wget -O- "${TOOLBOX_DOCKER_ARCHIVE}" | xz -cd | tar -C ${tmpdir} -xf -
layer=$(find ${tmpdir} -name layer.tar -type f)
sudo tar -C ${machinepath} -xf ${layer}
trap - EXIT PIPE
sudo rm -rf ${tmpdir}
else
echo "Error: No toolbox filesystem specified." >&2
exit 1