mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-07-04 02:56:18 +00:00
rootfs: Print attempt number after max check
With the old code it was possible to see odd messages like: "INFO: Create root disk image. Attempt 6 out of 5." Move the attempt number print to after we check against the max Fixes #251 Signed-off-by: Matt Fischer <matt@mattfischer.com>
This commit is contained in:
parent
ecd072430f
commit
ad5d879f8c
@ -205,10 +205,10 @@ detach()
|
|||||||
create_rootfs_disk()
|
create_rootfs_disk()
|
||||||
{
|
{
|
||||||
ATTEMPT_NUM=$(($ATTEMPT_NUM+1))
|
ATTEMPT_NUM=$(($ATTEMPT_NUM+1))
|
||||||
info "Create root disk image. Attempt ${ATTEMPT_NUM} out of ${MAX_ATTEMPTS}."
|
|
||||||
if [ ${ATTEMPT_NUM} -gt ${MAX_ATTEMPTS} ]; then
|
if [ ${ATTEMPT_NUM} -gt ${MAX_ATTEMPTS} ]; then
|
||||||
die "Unable to create root disk image."
|
die "Unable to create root disk image."
|
||||||
fi
|
fi
|
||||||
|
info "Create root disk image. Attempt ${ATTEMPT_NUM} out of ${MAX_ATTEMPTS}."
|
||||||
|
|
||||||
calculate_img_size
|
calculate_img_size
|
||||||
if [ ${OLD_IMG_SIZE} -ne 0 ]; then
|
if [ ${OLD_IMG_SIZE} -ne 0 ]; then
|
||||||
|
Loading…
Reference in New Issue
Block a user