Only run the cleanup when updating ports.
This commit is contained in:
parent
955f3cd329
commit
8744f8f547
@ -97,14 +97,14 @@ function cmd_start {
|
|||||||
portshaker -U
|
portshaker -U
|
||||||
portshaker -M
|
portshaker -M
|
||||||
PORTUPDATE=$(date +%s)
|
PORTUPDATE=$(date +%s)
|
||||||
|
# Cleanup old unused dist files
|
||||||
|
poudriere distclean -y -p "$PORTS" -f /usr/local/etc/poudriere.d/$JAIL-$PORTS-$SET-pkglist
|
||||||
|
poudriere logclean -y "$LOG_RETENTION_DAYS"
|
||||||
fi
|
fi
|
||||||
if [ $((now - LASTBUILD)) -gt "$BUILD_SECONDS" ]; then
|
if [ $((now - LASTBUILD)) -gt "$BUILD_SECONDS" ]; then
|
||||||
log "Building ports for $JAIL-$PORTS-$SET"
|
log "Building ports for $JAIL-$PORTS-$SET"
|
||||||
build -j "$JAIL" -p "$PORTS" -z "$SET" -f /usr/local/etc/poudriere.d/$JAIL-$PORTS-$SET-pkglist
|
build -j "$JAIL" -p "$PORTS" -z "$SET" -f /usr/local/etc/poudriere.d/$JAIL-$PORTS-$SET-pkglist
|
||||||
LASTBUILD=$(date +%s)
|
LASTBUILD=$(date +%s)
|
||||||
# Cleanup old unused dist files
|
|
||||||
poudriere distclean -y -p "$PORTS" -f /usr/local/etc/poudriere.d/$JAIL-$PORTS-$SET-pkglist
|
|
||||||
poudriere logclean -y "$LOG_RETENTION_DAYS"
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
cat > "$TIMES_FILE" <<EOF
|
cat > "$TIMES_FILE" <<EOF
|
||||||
|
Loading…
Reference in New Issue
Block a user