Skip to content

Commit

Permalink
do not retry automatically on disk full
Browse files Browse the repository at this point in the history
except for chroot builds where it still may be useful
  • Loading branch information
adrianschroeter committed Jan 8, 2020
1 parent dc9540e commit 8273e16
Showing 1 changed file with 14 additions and 13 deletions.
27 changes: 14 additions & 13 deletions build
Original file line number Diff line number Diff line change
Expand Up @@ -408,23 +408,24 @@ cleanup_and_exit () {
# add build time statistics
recipe_build_time_statistics

# check for disk full
if test "$1" -eq 1 -a -x /bin/df ; then
echo
echo "$HOST failed \"build $RECIPEFILE\" at `date --utc`."
echo
# okay, it failed, but maybe because disk space?
if df $BUILD_ROOT 2>/dev/null | grep -q "100%"; then
df $BUILD_ROOT 2>/dev/null
# chroot environment only
if test -z "$VM_TYPE" -o -n "$RUNNING_IN_VM" ; then
# check for disk full for an automatic build retry
if test "$1" -eq 1 -a -x /bin/df ; then
echo
echo "$HOST ran out of disk space. Please try again."
echo "$HOST failed \"build $RECIPEFILE\" at `date --utc`."
echo
set 3
# okay, it failed, but maybe because disk space?
if df $BUILD_ROOT 2>/dev/null | grep -q "100%"; then
df $BUILD_ROOT 2>/dev/null
echo
echo "$HOST ran out of disk space. Please try again."
echo
set 3
fi
fi
fi

# run recipe cleanup code
if test -z "$VM_TYPE" -o -n "$RUNNING_IN_VM" ; then
# run recipe cleanup code
test -n "$BUILDTYPE" && recipe_cleanup
fi

Expand Down

0 comments on commit 8273e16

Please sign in to comment.