[Qa-jenkins-scm] [Git][qa/jenkins.debian.net][master] Revert "properly delete old schroot overlays"

Holger Levsen (@holger) gitlab at salsa.debian.org
Sat Jul 3 10:00:13 BST 2021



Holger Levsen pushed to branch master at Debian QA / jenkins.debian.net


Commits:
4caa6431 by Holger Levsen at 2021-07-03T10:59:59+02:00
Revert "properly delete old schroot overlays"

This reverts commit 99ca0c3da556fcb05f0f708c50d91120d20fe1f8.

- - - - -


2 changed files:

- bin/reproducible_maintenance.sh
- hosts/jenkins/etc/sudoers.d/jenkins


Changes:

=====================================
bin/reproducible_maintenance.sh
=====================================
@@ -410,10 +410,10 @@ if [ "$HOSTNAME" = "$MAINNODE" ] ; then
 		dir=/var/lib/schroot/$path/
 		if [ "$path" = "session" ] ; then
 			FILETYPE=f
-			RM_OPTIONS="-v"
+			RM=rm
 		else
 			FILETYPE=d
-			RM_OPTIONS="-rv --one-file-system"
+			RM=rmdir
 		fi
 		OLDSTUFF=$(find "$dir" -name "jenkins-reproducible-*-diffoscope-*" -mindepth 1 -maxdepth 1 -type $FILETYPE -mtime +1 -exec ls -lad {} \; || true)
 		if [ ! -z "$OLDSTUFF" ]; then
@@ -422,7 +422,7 @@ if [ "$HOSTNAME" = "$MAINNODE" ] ; then
 			echo "$OLDSTUFF" | sed "s#$dir#./#g"
 
 			echo
-			find "$dir" -name "jenkins-reproducible-*-diffoscope-*" -mindepth 1 -maxdepth 1 -type $FILETYPE -mtime +1 -exec sudo rm $RM_OPTIONS {} \; || true
+			find "$dir" -name "jenkins-reproducible-*-diffoscope-*" -mindepth 1 -maxdepth 1 -type $FILETYPE -mtime +1 -exec sudo $RM -v {} \; || true
 			OLDSTUFF=$(find "$dir" -name "jenkins-reproducible-*-diffoscope-*" -mindepth 1 -maxdepth 1 -type $FILETYPE -mtime +1 -exec ls -lad {} \; || true)
 			if [ ! -z "$OLDSTUFF" ]; then
 				echo


=====================================
hosts/jenkins/etc/sudoers.d/jenkins
=====================================
@@ -23,8 +23,8 @@ jenkins ALL=  \
 	/bin/rm -rf --one-file-system /var/lib/sbuild/build/*, \
 	/bin/rm -rf --one-file-system /tmp/*, \
 	/bin/rm -rv --one-file-system /tmp/*, \
-	/bin/rm -rv --one-file-system /var/lib/schroot/*, \
 	/bin/rm -v /var/lib/schroot/*, \
+	/bin/rmdir -v /var/lib/schroot/*, \
 	/bin/mv /chroots/* /schroots/*, \
 	/bin/mv /schroots/* /schroots/*, \
 	/bin/umount -l /chroots/*, \



View it on GitLab: https://salsa.debian.org/qa/jenkins.debian.net/-/commit/4caa6431905b6fdb03cfb4399aad47849a97c8d7

-- 
View it on GitLab: https://salsa.debian.org/qa/jenkins.debian.net/-/commit/4caa6431905b6fdb03cfb4399aad47849a97c8d7
You're receiving this email because of your account on salsa.debian.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/qa-jenkins-scm/attachments/20210703/28f996d7/attachment-0001.htm>


More information about the Qa-jenkins-scm mailing list