summaryrefslogtreecommitdiffstats
path: root/tools/builder_common.sh
diff options
context:
space:
mode:
authorRenato Botelho <renato@netgate.com>2015-09-04 13:09:21 -0300
committerRenato Botelho <renato@netgate.com>2015-09-04 13:09:21 -0300
commitce96c1310e2178e298b73ba96a90a15c9eebfa95 (patch)
treea1f9733723a793d2a99eab3f138e99983f4da6e9 /tools/builder_common.sh
parent45b13882fdfb7e0ff971e5249e1adfacbaed59da (diff)
downloadpfsense-ce96c1310e2178e298b73ba96a90a15c9eebfa95.zip
pfsense-ce96c1310e2178e298b73ba96a90a15c9eebfa95.tar.gz
Fix snapshots log rotate
Diffstat (limited to 'tools/builder_common.sh')
-rw-r--r--tools/builder_common.sh6
1 files changed, 4 insertions, 2 deletions
diff --git a/tools/builder_common.sh b/tools/builder_common.sh
index 691bb4e..f1f6a76 100644
--- a/tools/builder_common.sh
+++ b/tools/builder_common.sh
@@ -1951,12 +1951,14 @@ snapshots_update_status() {
# Copy the current log file to $filename.old on
# the snapshot www server (real time logs)
snapshots_rotate_logfile() {
- if [ -n "$MASTER_BUILDER_SSH_LOG_DEST" -a -z "${DO_NOT_UPLOAD}" ]; then
+ if [ -z "${DO_NOT_UPLOAD}" -a -n "${RSYNCIP}" ]; then
scp -q $SNAPSHOTSLOGFILE ${RSYNCUSER}@${RSYNCIP}:${RSYNCLOGS}/build.log.old
fi
# Cleanup log file
- echo "" > $SNAPSHOTSLOGFILE
+ rm -f $SNAPSHOTSLOGFILE; touch $SNAPSHOTSLOGFILE
+ rm -f $SNAPSHOTSLASTUPDATE; touch $SNAPSHOTSLASTUPDATE
+
}
snapshots_copy_to_staging_nanobsd() {
OpenPOWER on IntegriCloud