Skip to content
Snippets Groups Projects
Unverified Commit 4ee93922 authored by Maxim Cournoyer's avatar Maxim Cournoyer
Browse files

Jenkinsfile: Allow partial deployments.

When a packaging target fails to build, deploy the successful builds
to the repository anyway.

* Jenkinsfile (BUILD_OWN_QT): Remove parameter.  The Qt builds are now
implicitly made as part of the regular packaging targets.
(Build packages): Wrap make invocation in a catchError so that the
stage appears as failed while the build is marked as a success, which
allows the 'Sign & deploy packages' stage to run despite packaging
errors.

Change-Id: I5785d154f5e1963aa824576f7f0f62043446456a
parent 06b6cb35
No related branches found
No related tags found
No related merge requests found
......@@ -67,9 +67,6 @@ pipeline {
' submodules at their Git-recorded commit. When left ' +
'unticked (the default), checkout the submodules at ' +
'their latest commit from their main remote branch.')
booleanParam(name: 'BUILD_OWN_QT',
defaultValue: false,
description: 'Whether to build our own Qt packages.')
booleanParam(name: 'BUILD_ARM',
defaultValue: false,
description: 'Whether to build ARM packages.')
......@@ -143,14 +140,10 @@ See https://wiki.savoirfairelinux.com/wiki/Jenkins.jami.net#Configuration"
}
TARGETS = targetsText.split(/\s/)
if (!params.BUILD_OWN_QT) {
TARGETS = TARGETS.findAll { !it.endsWith('_qt') }
}
if (!params.BUILD_ARM) {
TARGETS = TARGETS.findAll { !(it =~ /_(armhf|arm64)$/) }
}
def stages = [:]
TARGETS.each { target ->
......@@ -162,12 +155,15 @@ See https://wiki.savoirfairelinux.com/wiki/Jenkins.jami.net#Configuration"
node('linux-builder') {
cleanWs()
unstash 'release-tarball'
sh """
tar xf *.tar.gz --strip-components=1
make ${target}
"""
stash(includes: 'packages/**',
name: target)
catchError(buildResult: 'SUCCESS',
stageResult: 'FAILURE') {
sh """
tar xf *.tar.gz --strip-components=1
make ${target}
"""
stash(includes: 'packages/**',
name: target)
}
}
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment