[Git][qa/jenkins.debian.net][master] djm: delete stale log lock file
Holger Levsen (@holger)
gitlab at salsa.debian.org
Tue Apr 7 01:22:11 BST 2026
Holger Levsen pushed to branch master at Debian QA / jenkins.debian.net
Commits:
383c8ea7 by Mattia Rizzolo at 2026-04-07T02:22:04+02:00
djm: delete stale log lock file
Signed-off-by: Mattia Rizzolo <mattia at debian.org>
(cherry picked from commit 5541f34c9348deaa95b369181c6abf2cda306ab8)
Signed-off-by: Holger Levsen <holger at layer-acht.org>
- - - - -
1 changed file:
- bin/djm
Changes:
=====================================
bin/djm
=====================================
@@ -686,8 +686,14 @@ djm_do() {
echo "$LOGDATE, $SHORTNODE, $ACTION, $REASON" | tee -a $LOGFILE
LOGGED=true
else
- echo "$LOCK exists, waiting 3 seconds until retry."
- sleep 3
+ # lock file older than two days
+ if [[ $(( "$(date -u +%s)" - "$(stat --printf='%Z' ~/.djm.log.lock)")) -gt 172800 ]]; then
+ echo "$LOCK exists, but it's older than 2 days, therfore deleting and continueing"
+ rm "$LOCK"
+ else
+ echo "$LOCK exists, waiting 3 seconds until retry."
+ sleep 3
+ fi
fi
done
done
View it on GitLab: https://salsa.debian.org/qa/jenkins.debian.net/-/commit/383c8ea7ba583ef2dce3cb16196aaf63561ee3ae
--
View it on GitLab: https://salsa.debian.org/qa/jenkins.debian.net/-/commit/383c8ea7ba583ef2dce3cb16196aaf63561ee3ae
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/20260407/c01afd8a/attachment-0001.htm>
More information about the Qa-jenkins-scm
mailing list