mirror of
https://github.com/flatcar/scripts.git
synced 2025-11-29 14:31:46 +01:00
cros_make_image_bootable is not compatible with restart_inside_chroot
restart_inside_chroot first assumes that the calling script is in src/scripts. Next any paths are not converted when passed so if someone passes the most recent image, this will also not be interpreted correctly. Change-Id: Icb2dfc661eb84e134b4d8c5cf0354a6c1ab161f0 BUG= TEST=Manually tested running outside chroot (getting error) and inside chroot. Review URL: http://codereview.chromium.org/3421025
This commit is contained in:
parent
cc09f84b5e
commit
e8c3cdc91c
@ -14,8 +14,12 @@ if [ ! -r "${COMMON_PATH}" ]; then
|
|||||||
echo "ERROR! Cannot find common.sh: ${COMMON_PATH}" 1>&2
|
echo "ERROR! Cannot find common.sh: ${COMMON_PATH}" 1>&2
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
. "$(dirname "$0")/../common.sh"
|
. "$(dirname "$0")/../common.sh"
|
||||||
|
|
||||||
|
# Script must be run inside the chroot.
|
||||||
|
assert_inside_chroot
|
||||||
|
|
||||||
set -e
|
set -e
|
||||||
. "$(dirname "$0")/../chromeos-common.sh" # for partoffset and partsize
|
. "$(dirname "$0")/../chromeos-common.sh" # for partoffset and partsize
|
||||||
|
|
||||||
@ -46,8 +50,6 @@ if [ ! -r "${IMAGE}" ]; then
|
|||||||
die "${IMAGE} cannot be read!"
|
die "${IMAGE} cannot be read!"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Script must be run inside the chroot.
|
|
||||||
restart_in_chroot_if_needed $*
|
|
||||||
|
|
||||||
locate_gpt
|
locate_gpt
|
||||||
set +e
|
set +e
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user