Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Debian QA
jenkins.debian.net
Commits
1fb3417e
Verified
Commit
1fb3417e
authored
Apr 04, 2018
by
Mattia Rizzolo
Browse files
reproducible debian: Add a mean to very gracefully stop the rb workers
Signed-off-by:
Mattia Rizzolo
<
mattia@debian.org
>
parent
b4426986
Changes
2
Hide whitespace changes
Inline
Side-by-side
bin/reproducible_worker.sh
View file @
1fb3417e
#!/bin/bash
#!/bin/bash
# vim: set noexpandtab:
# Copyright © 2017 Holger Levsen (holger@layer-acht.org)
# Copyright © 2017 Holger Levsen (holger@layer-acht.org)
# © 2018 Mattia Rizolo <mattia@debian.org>
# released under the GPLv=2
# released under the GPLv=2
set
-e
set
-e
...
@@ -41,6 +43,11 @@ while true ; do
...
@@ -41,6 +43,11 @@ while true ; do
break
break
fi
fi
fi
fi
LOCKFILE
=
"/var/lib/jenkins/NO-RB-BUILDERS-PLEASE"
if
[
-f
"
$LOCKFILE
"
]
;
echo
"The lockfile
$LOCKFILE
is present, thus stopping this"
break
fi
# sleep up to 2.3 seconds (additionally to the random sleep reproducible_build.sh does anyway)
# sleep up to 2.3 seconds (additionally to the random sleep reproducible_build.sh does anyway)
/bin/sleep
$(
echo
"scale=1 ;
$(
shuf
-i
1-23
-n
1
)
/10"
| bc
)
/bin/sleep
$(
echo
"scale=1 ;
$(
shuf
-i
1-23
-n
1
)
/10"
| bc
)
...
...
hosts/jenkins/etc/systemd/system/reproducible_build@.service
View file @
1fb3417e
[Unit]
[Unit]
Description
=
Build service for reproducible-builds jobs
Description
=
Build service for reproducible-builds jobs
ConditionPathExists
=
!/var/lib/jenkins/NO-RB-BUILDERS-PLEASE
[Service]
[Service]
# Restart whenever the script exits, without rate limiting:
# Restart whenever the script exits, without rate limiting:
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment