Skip to content

Commit 70295ae

Browse files
Vitexusclaude
andcommitted
fix: wait for RebulidDEBRepoByAnsible before apt test installation
Polls the Jenkins job color before entering the Test stage so apt-get does not hit the repository while it is being rebuilt by the Ansible republish job. Uses waitUntil instead of buildBlocker (plugin absent). Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent 370cfd1 commit 70295ae

1 file changed

Lines changed: 5 additions & 7 deletions

File tree

debian/Jenkinsfile

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,7 @@ String distroCodename = ''
99
String ver = ''
1010

1111
properties([
12-
copyArtifactPermission('*'),
13-
buildBlocker(
14-
useBuildBlocker: true,
15-
blockLevel: 'GLOBAL',
16-
scanQueueFor: 'ALL',
17-
blockingJobs: 'RebulidDEBRepoByAnsible'
18-
)
12+
copyArtifactPermission('*')
1913
])
2014
node() {
2115
ansiColor('xterm') {
@@ -58,6 +52,10 @@ distributions.each {
5852
}
5953

6054
stage('Test ' + distribution) {
55+
waitUntil(initialRecurrencePeriod: 30000) {
56+
def color = sh(script: "curl -sf 'https://jenkins.proxy.spojenet.cz/job/RebulidDEBRepoByAnsible/api/json?tree=color' 2>/dev/null | grep -o '"color":"[^"]*"' | cut -d'"' -f4 || echo 'blue'", returnStdout: true).trim()
57+
return !color.endsWith('_anime')
58+
}
6159
buildImage.inside {
6260
def debconf_debug = 0 //Set to "5" or "developer" to debug debconf
6361
sh 'cd $WORKSPACE/dist/debian/ ; dpkg-scanpackages . /dev/null | gzip -9c > Packages.gz; cd $WORKSPACE'

0 commit comments

Comments
 (0)