Merge "Adding a new project parameter on multijob"
This commit is contained in:
commit
3765657ec6
|
@ -1531,6 +1531,8 @@ def multijob(parser, xml_parent, data):
|
|||
to the other job (optional)
|
||||
* **predefined-parameters** (`str`) -- Pass predefined
|
||||
parameters to the other job (optional)
|
||||
* **abort-all-job** (`bool`) -- Kill allsubs job and the phase job,
|
||||
if this subjob is killed (default false)
|
||||
* **enable-condition** (`str`) -- Condition to run the
|
||||
job in groovy script format (optional)
|
||||
* **kill-phase-on** (`str`) -- Stop the phase execution
|
||||
|
@ -1609,6 +1611,10 @@ def multijob(parser, xml_parent, data):
|
|||
properties = XML.SubElement(param, 'properties')
|
||||
properties.text = predefined_parameters
|
||||
|
||||
# Abort all other job
|
||||
abortAllJob = str(project.get('abort-all-job', False)).lower()
|
||||
XML.SubElement(phaseJob, 'abortAllJob').text = abortAllJob
|
||||
|
||||
# Enable Condition
|
||||
enable_condition = project.get('enable-condition')
|
||||
if enable_condition is not None:
|
||||
|
|
|
@ -17,6 +17,7 @@
|
|||
<combineQueuedCommits>false</combineQueuedCommits>
|
||||
</hudson.plugins.git.GitRevisionBuildParameters>
|
||||
</configs>
|
||||
<abortAllJob>true</abortAllJob>
|
||||
</com.tikal.jenkins.plugins.multijob.PhaseJobsConfig>
|
||||
<com.tikal.jenkins.plugins.multijob.PhaseJobsConfig>
|
||||
<jobName>PhaseOneJobB</jobName>
|
||||
|
@ -27,6 +28,7 @@
|
|||
<failTriggerOnMissing>true</failTriggerOnMissing>
|
||||
</hudson.plugins.parameterizedtrigger.FileBuildParameters>
|
||||
</configs>
|
||||
<abortAllJob>false</abortAllJob>
|
||||
</com.tikal.jenkins.plugins.multijob.PhaseJobsConfig>
|
||||
</phaseJobs>
|
||||
</com.tikal.jenkins.plugins.multijob.MultiJobBuilder>
|
||||
|
@ -42,11 +44,13 @@
|
|||
<properties>foo=bar</properties>
|
||||
</hudson.plugins.parameterizedtrigger.PredefinedBuildParameters>
|
||||
</configs>
|
||||
<abortAllJob>false</abortAllJob>
|
||||
</com.tikal.jenkins.plugins.multijob.PhaseJobsConfig>
|
||||
<com.tikal.jenkins.plugins.multijob.PhaseJobsConfig>
|
||||
<jobName>PhaseTwoJobB</jobName>
|
||||
<currParams>false</currParams>
|
||||
<configs/>
|
||||
<abortAllJob>false</abortAllJob>
|
||||
<enableCondition>true</enableCondition>
|
||||
<condition>${BUILDNUMBER} % 2 == 1</condition>
|
||||
<killPhaseOnJobResultCondition>UNSTABLE</killPhaseOnJobResultCondition>
|
||||
|
|
|
@ -8,6 +8,7 @@ builders:
|
|||
node-label-name: "vm_name"
|
||||
node-label: "agent-${BUILD_NUMBER}"
|
||||
git-revision: true
|
||||
abort-all-job: true
|
||||
- name: PhaseOneJobB
|
||||
current-parameters: true
|
||||
property-file: build.props
|
||||
|
|
Loading…
Reference in New Issue