[Git][qa/jenkins.debian.net][master] rdn backups: also compress old backups
Holger Levsen (@holger)
gitlab at salsa.debian.org
Tue Nov 17 14:12:24 GMT 2026
Holger Levsen pushed to branch master at Debian QA / jenkins.debian.net
Commits:
5894fe01 by Holger Levsen at 2026-11-17T15:12:14+01:00
rdn backups: also compress old backups
Signed-off-by: Holger Levsen <holger at layer-acht.org>
- - - - -
1 changed file:
- bin/rebuilderd_db_backup_compress.sh
Changes:
=====================================
bin/rebuilderd_db_backup_compress.sh
=====================================
@@ -9,16 +9,20 @@
set -e
#
-# actually compress those backups
+# compress backups except those from today
#
TODAY=$(date '+%Y-%m-%d' -u)
-FILES=$(find /srv/rebuilderd/*/stats/db-backup/db-back-$TODAY -type f ! -name '*.zst' ! -name '*.xz' 2>/dev/null || exit 0)
-for i in $FILES ; do
- zstdmt --rm -4 $i
+FILES=$(find /srv/rebuilderd/*/stats/db-backup/db-back-* -type f ! -name '*.zst' ! -name '*.xz' 2>/dev/null | grep -v db-back-$TODAY || true)
+for i in "$FILES" ; do
+ if [ -z "$i" ] ; then
+ continue
+ else
+ zstdmt --rm -4 $i
+ fi
done
#
-# actually delete old backups
+# delete old backups
#
THIS_MONTH=$(date -u '+%Y-%m')
LAST_MONTH=$(date -u -d '1 month ago' '+%Y-%m')
View it on GitLab: https://salsa.debian.org/qa/jenkins.debian.net/-/commit/5894fe01ccbef6b01fc7dee05c29db6968939090
--
View it on GitLab: https://salsa.debian.org/qa/jenkins.debian.net/-/commit/5894fe01ccbef6b01fc7dee05c29db6968939090
You're receiving this email because of your account on salsa.debian.org. Manage all notifications: https://salsa.debian.org/-/profile/notifications | Help: https://salsa.debian.org/help
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/qa-jenkins-scm/attachments/20261117/b050f2ed/attachment-0001.htm>
More information about the Qa-jenkins-scm
mailing list