Add method to test dev versions of lftools
[releng/global-jjb.git] / jjb-test / expected-xml / gerrit-ciman-packer-verify
1 <?xml version="1.0" encoding="utf-8"?>
2 <project>
3   <actions/>
4   <description>&lt;!-- Managed by Jenkins Job Builder --&gt;</description>
5   <keepDependencies>false</keepDependencies>
6   <blockBuildWhenDownstreamBuilding>false</blockBuildWhenDownstreamBuilding>
7   <blockBuildWhenUpstreamBuilding>false</blockBuildWhenUpstreamBuilding>
8   <concurrentBuild>true</concurrentBuild>
9   <assignedNode>build-vm</assignedNode>
10   <canRoam>false</canRoam>
11   <properties>
12     <jenkins.model.BuildDiscarderProperty>
13       <strategy class="hudson.tasks.LogRotator">
14         <daysToKeep>7</daysToKeep>
15         <numToKeep>-1</numToKeep>
16         <artifactDaysToKeep>-1</artifactDaysToKeep>
17         <artifactNumToKeep>0</artifactNumToKeep>
18       </strategy>
19     </jenkins.model.BuildDiscarderProperty>
20     <hudson.model.ParametersDefinitionProperty>
21       <parameterDefinitions>
22         <hudson.model.StringParameterDefinition>
23           <name>PROJECT</name>
24           <description>Parameter to identify a Gerrit project. This is typically the
25 project repo path as exists in Gerrit.
26 For example: ofextensions/circuitsw
27 </description>
28           <defaultValue>releng/ciman</defaultValue>
29         </hudson.model.StringParameterDefinition>
30         <hudson.model.StringParameterDefinition>
31           <name>STREAM</name>
32           <description>Stream is often set to the same name as 'branch' but can
33 sometimes be used as a name representing a project's release code
34 name.
35 </description>
36           <defaultValue>master</defaultValue>
37         </hudson.model.StringParameterDefinition>
38         <hudson.model.StringParameterDefinition>
39           <name>GERRIT_PROJECT</name>
40           <description>Parameter to identify Gerrit project. This is typically the
41 project repo path as exists in Gerrit.
42 For example: ofextensions/circuitsw
43
44 Note that Gerrit will override this parameter automatically if a
45 job is triggered by Gerrit.
46 </description>
47           <defaultValue>releng/ciman</defaultValue>
48         </hudson.model.StringParameterDefinition>
49         <hudson.model.StringParameterDefinition>
50           <name>GERRIT_BRANCH</name>
51           <description>Parameter to identify a Gerrit branch.
52
53 Note that Gerrit will override this parameter automatically if a
54 job is triggered by Gerrit.
55 </description>
56           <defaultValue>master</defaultValue>
57         </hudson.model.StringParameterDefinition>
58         <hudson.model.StringParameterDefinition>
59           <name>GERRIT_REFSPEC</name>
60           <description>Parameter to identify a refspec when pulling from Gerrit.
61
62 Note that Gerrit will override this parameter automatically if a
63 job is triggered by Gerrit.
64 </description>
65           <defaultValue/>
66         </hudson.model.StringParameterDefinition>
67         <hudson.model.StringParameterDefinition>
68           <name>PACKER_VERSION</name>
69           <description>Packer version to download and install.</description>
70           <defaultValue>1.0.2</defaultValue>
71         </hudson.model.StringParameterDefinition>
72       </parameterDefinitions>
73     </hudson.model.ParametersDefinitionProperty>
74   </properties>
75   <scm class="hudson.plugins.git.GitSCM">
76     <configVersion>2</configVersion>
77     <userRemoteConfigs>
78       <hudson.plugins.git.UserRemoteConfig>
79         <name>origin</name>
80         <refspec>$GERRIT_REFSPEC</refspec>
81         <url>$GIT_URL/$GERRIT_PROJECT</url>
82         <credentialsId>test-credential</credentialsId>
83       </hudson.plugins.git.UserRemoteConfig>
84     </userRemoteConfigs>
85     <branches>
86       <hudson.plugins.git.BranchSpec>
87         <name>refs/heads/$GERRIT_BRANCH</name>
88       </hudson.plugins.git.BranchSpec>
89     </branches>
90     <excludedUsers/>
91     <buildChooser class="com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.GerritTriggerBuildChooser"/>
92     <doGenerateSubmoduleConfigurations>false</doGenerateSubmoduleConfigurations>
93     <authorOrCommitter>false</authorOrCommitter>
94     <wipeOutWorkspace>true</wipeOutWorkspace>
95     <pruneBranches>false</pruneBranches>
96     <remotePoll>false</remotePoll>
97     <gitTool>Default</gitTool>
98     <submoduleCfg class="list"/>
99     <relativeTargetDir/>
100     <reference/>
101     <gitConfigName/>
102     <gitConfigEmail/>
103     <skipTag>true</skipTag>
104     <scmName/>
105     <useShallowClone>false</useShallowClone>
106     <ignoreNotifyCommit>false</ignoreNotifyCommit>
107     <extensions>
108       <hudson.plugins.git.extensions.impl.SubmoduleOption>
109         <disableSubmodules>false</disableSubmodules>
110         <recursiveSubmodules>true</recursiveSubmodules>
111         <trackingSubmodules>false</trackingSubmodules>
112         <reference/>
113         <timeout>10</timeout>
114       </hudson.plugins.git.extensions.impl.SubmoduleOption>
115       <hudson.plugins.git.extensions.impl.WipeWorkspace/>
116     </extensions>
117   </scm>
118   <triggers class="vector">
119     <com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.GerritTrigger>
120       <spec/>
121       <gerritProjects>
122         <com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.data.GerritProject>
123           <compareType>ANT</compareType>
124           <pattern>releng/ciman</pattern>
125           <branches>
126             <com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.data.Branch>
127               <compareType>ANT</compareType>
128               <pattern>**/master</pattern>
129             </com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.data.Branch>
130           </branches>
131           <filePaths>
132             <com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.data.FilePath>
133               <compareType>ANT</compareType>
134               <pattern>packer/vars/['centos', 'ubuntu1604'].json</pattern>
135             </com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.data.FilePath>
136             <com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.data.FilePath>
137               <compareType>ANT</compareType>
138               <pattern>packer/templates/['java-builder', 'mininet'].json</pattern>
139             </com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.data.FilePath>
140             <com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.data.FilePath>
141               <compareType>ANT</compareType>
142               <pattern>packer/provision/['java-builder', 'mininet'].sh</pattern>
143             </com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.data.FilePath>
144             <com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.data.FilePath>
145               <compareType>ANT</compareType>
146               <pattern>packer/provision/lib/**</pattern>
147             </com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.data.FilePath>
148           </filePaths>
149           <disableStrictForbiddenFileVerification>false</disableStrictForbiddenFileVerification>
150         </com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.data.GerritProject>
151       </gerritProjects>
152       <skipVote>
153         <onSuccessful>false</onSuccessful>
154         <onFailed>false</onFailed>
155         <onUnstable>false</onUnstable>
156         <onNotBuilt>false</onNotBuilt>
157       </skipVote>
158       <silentMode>false</silentMode>
159       <silentStartMode>false</silentStartMode>
160       <escapeQuotes>true</escapeQuotes>
161       <noNameAndEmailParameters>false</noNameAndEmailParameters>
162       <readableMessage>false</readableMessage>
163       <dependencyJobsNames/>
164       <notificationLevel/>
165       <dynamicTriggerConfiguration>False</dynamicTriggerConfiguration>
166       <triggerConfigURL/>
167       <allowTriggeringUnreviewedPatches>false</allowTriggeringUnreviewedPatches>
168       <triggerOnEvents>
169         <com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.events.PluginPatchsetCreatedEvent>
170           <excludeDrafts>false</excludeDrafts>
171           <excludeTrivialRebase>false</excludeTrivialRebase>
172           <excludeNoCodeChange>false</excludeNoCodeChange>
173         </com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.events.PluginPatchsetCreatedEvent>
174         <com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.events.PluginDraftPublishedEvent/>
175         <com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.events.PluginCommentAddedContainsEvent>
176           <commentAddedCommentContains>recheck$</commentAddedCommentContains>
177         </com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.events.PluginCommentAddedContainsEvent>
178       </triggerOnEvents>
179       <buildStartMessage/>
180       <buildFailureMessage/>
181       <buildSuccessfulMessage/>
182       <buildUnstableMessage/>
183       <buildNotBuiltMessage/>
184       <buildUnsuccessfulFilepath/>
185       <customUrl/>
186       <serverName>test-server</serverName>
187     </com.sonyericsson.hudson.plugins.gerrit.trigger.hudsontrigger.GerritTrigger>
188   </triggers>
189   <builders>
190     <org.jenkinsci.plugins.configfiles.builder.ConfigFileBuildStep plugin="config-file-provider">
191       <managedFiles>
192         <org.jenkinsci.plugins.configfiles.buildwrapper.ManagedFile>
193           <fileId>ci-packer-cloud-env</fileId>
194           <targetLocation/>
195           <variable>CLOUDENV</variable>
196         </org.jenkinsci.plugins.configfiles.buildwrapper.ManagedFile>
197       </managedFiles>
198     </org.jenkinsci.plugins.configfiles.builder.ConfigFileBuildStep>
199     <EnvInjectBuilder>
200       <info>
201         <propertiesContent>PACKER_VERSION=1.0.2
202 </propertiesContent>
203       </info>
204     </EnvInjectBuilder>
205     <hudson.tasks.Shell>
206       <command>#!/bin/bash
207 # SPDX-License-Identifier: EPL-1.0
208 ##############################################################################
209 # Copyright (c) 2017 The Linux Foundation and others.
210 #
211 # All rights reserved. This program and the accompanying materials
212 # are made available under the terms of the Eclipse Public License v1.0
213 # which accompanies this distribution, and is available at
214 # http://www.eclipse.org/legal/epl-v10.html
215 ##############################################################################
216 echo &quot;---&gt; packer-install.sh&quot;
217 # The script checks for the packer binaries and installs the binary
218 # if its not available
219
220 # $PACKER_VERSION        : Define a packer version passed as job paramter
221
222 PACKER_VERSION=&quot;${PACKER_VERSION:-1.0.2}&quot;
223
224 # Ensure we fail the job if any steps fail.
225 set -eu -o pipefail
226 # Default packer binary made available on the build image
227 packer_bin=&quot;/usr/local/bin/packer.io&quot;
228
229 if hash &quot;$packer_bin&quot; 2&gt;/dev/null; then
230     echo &quot;packer.io command is available.&quot;
231 else
232     echo &quot;packer.io command not is available. Installing packer ...&quot;
233     # Installs Hashicorp's Packer binary, required for verify &amp; merge packer jobs
234     pushd packer
235     wget &quot;https://releases.hashicorp.com/packer/${PACKER_VERSION}/packer_${PACKER_VERSION}_linux_amd64.zip&quot;
236     mkdir -p &quot;${WORKSPACE}/bin&quot;
237     unzip &quot;packer_${PACKER_VERSION}_linux_amd64.zip&quot; -d ${WORKSPACE}/bin/
238     # rename packer to avoid conflict with binary in cracklib
239     mv ${WORKSPACE}/bin/packer &quot;${WORKSPACE}/bin/packer.io&quot;
240     popd
241 fi
242
243 #!/bin/bash
244 # SPDX-License-Identifier: EPL-1.0
245 ##############################################################################
246 # Copyright (c) 2017 The Linux Foundation and others.
247 #
248 # All rights reserved. This program and the accompanying materials
249 # are made available under the terms of the Eclipse Public License v1.0
250 # which accompanies this distribution, and is available at
251 # http://www.eclipse.org/legal/epl-v10.html
252 ##############################################################################
253 echo &quot;---&gt; packer-validate.sh&quot;
254 # The script validates an packers files.
255
256 # $CLOUDENV            :  Provides the cloud credential file.
257
258 # Ensure we fail the job if any steps fail.
259 set -eu -o pipefail
260
261 PACKER_LOGS_DIR=&quot;$WORKSPACE/archives/packer&quot;
262 mkdir -p &quot;$PACKER_LOGS_DIR&quot;
263 export PATH=&quot;${WORKSPACE}/bin:$PATH&quot;
264
265 cd packer
266 varfiles=(../packer/vars/*.json)
267 templates=(../packer/templates/*.json)
268
269 for varfile in &quot;${varfiles[@]}&quot;; do
270     for template in &quot;${templates[@]}&quot;; do
271         export PACKER_LOG=&quot;yes&quot; &amp;&amp; \
272         export PACKER_LOG_PATH=&quot;$PACKER_LOGS_DIR/packer-validate-${varfile##*/}-${template##*/}.log&quot; &amp;&amp; \
273                     packer.io validate -var-file=&quot;$CLOUDENV&quot; \
274                     -var-file=&quot;$varfile&quot; &quot;$template&quot;
275         if [ $? -ne 0 ]; then
276             break
277         fi
278     done
279 done
280 </command>
281     </hudson.tasks.Shell>
282     <hudson.tasks.Shell>
283       <command>#!/bin/bash
284 # SPDX-License-Identifier: EPL-1.0
285 ##############################################################################
286 # Copyright (c) 2017 The Linux Foundation and others.
287 #
288 # All rights reserved. This program and the accompanying materials
289 # are made available under the terms of the Eclipse Public License v1.0
290 # which accompanies this distribution, and is available at
291 # http://www.eclipse.org/legal/epl-v10.html
292 ##############################################################################
293 echo &quot;---&gt; packer-clear-credentials.sh&quot;
294
295 set +e  # DO NOT cause build failure if any of the rm calls fail.
296 rm &quot;$CLOUDENV&quot;
297 exit 0
298 </command>
299     </hudson.tasks.Shell>
300   </builders>
301   <publishers>
302     <org.jenkinsci.plugins.postbuildscript.PostBuildScript>
303       <buildSteps>
304         <hudson.tasks.Shell>
305           <command>#!/bin/bash
306 # SPDX-License-Identifier: EPL-1.0
307 ##############################################################################
308 # Copyright (c) 2017 The Linux Foundation and others.
309 #
310 # All rights reserved. This program and the accompanying materials
311 # are made available under the terms of the Eclipse Public License v1.0
312 # which accompanies this distribution, and is available at
313 # http://www.eclipse.org/legal/epl-v10.html
314 ##############################################################################
315 echo &quot;---&gt; sysstat.sh&quot;
316 set +e  # DON'T fail build if script fails.
317
318 OS=$(facter operatingsystem)
319 case &quot;$OS&quot; in
320     Ubuntu)
321         SYSSTAT_PATH=&quot;/var/log/sysstat&quot;
322
323         # Dont run the script when systat is not enabled by default
324         if ! grep --quiet 'ENABLED=&quot;true&quot;' &quot;/etc/default/sysstat&quot;; then
325             exit 0
326         fi
327     ;;
328     CentOS|RedHat)
329         SYSSTAT_PATH=&quot;/var/log/sa&quot;
330     ;;
331     *)
332         # nothing to do
333         exit 0
334     ;;
335 esac
336
337 SAR_DIR=&quot;$WORKSPACE/archives/sar-reports&quot;
338 mkdir -p &quot;$SAR_DIR&quot;
339 cp &quot;$SYSSTAT_PATH/&quot;* &quot;$_&quot;
340 # convert sar data to ascii format
341 while IFS=&quot;&quot; read -r s
342 do
343     [ -f &quot;$s&quot; ] &amp;&amp; LC_TIME=POSIX sar -A -f &quot;$s&quot; &gt; &quot;$SAR_DIR/sar${s//[!0-9]/}&quot;
344 done &lt; &lt;(find &quot;$SYSSTAT_PATH&quot; -name &quot;sa[0-9]*&quot; || true)
345
346 # DON'T fail build if script fails.
347 exit 0
348 </command>
349         </hudson.tasks.Shell>
350         <org.jenkinsci.plugins.configfiles.builder.ConfigFileBuildStep plugin="config-file-provider">
351           <managedFiles>
352             <org.jenkinsci.plugins.configfiles.buildwrapper.ManagedFile>
353               <fileId>jenkins-log-archives-settings</fileId>
354               <targetLocation/>
355               <variable>SETTINGS_FILE</variable>
356             </org.jenkinsci.plugins.configfiles.buildwrapper.ManagedFile>
357           </managedFiles>
358         </org.jenkinsci.plugins.configfiles.builder.ConfigFileBuildStep>
359         <EnvInjectBuilder>
360           <info>
361             <propertiesContent>SERVER_ID=logs</propertiesContent>
362           </info>
363         </EnvInjectBuilder>
364         <hudson.tasks.Shell>
365           <command>#!/bin/bash
366 # SPDX-License-Identifier: EPL-1.0
367 ##############################################################################
368 # Copyright (c) 2017 The Linux Foundation and others.
369 #
370 # All rights reserved. This program and the accompanying materials
371 # are made available under the terms of the Eclipse Public License v1.0
372 # which accompanies this distribution, and is available at
373 # http://www.eclipse.org/legal/epl-v10.html
374 ##############################################################################
375 echo &quot;---&gt; create-netrc.sh&quot;
376
377 # Ensure we fail the job if any steps fail.
378 set -eu -o pipefail
379
380 NEXUS_URL=&quot;${NEXUS_URL:-$NEXUSPROXY}&quot;
381 CREDENTIAL=$(xmlstarlet sel -N &quot;x=http://maven.apache.org/SETTINGS/1.0.0&quot; \
382     -t -m &quot;/x:settings/x:servers/x:server[x:id='${SERVER_ID}']&quot; \
383     -v x:username -o &quot;:&quot; -v x:password \
384     &quot;$SETTINGS_FILE&quot;)
385
386 machine=$(echo &quot;$NEXUS_URL&quot; | awk -F/ '{print $3}')
387 user=$(echo &quot;$CREDENTIAL&quot; | cut -f1 -d:)
388 pass=$(echo &quot;$CREDENTIAL&quot; | cut -f2 -d:)
389
390 echo &quot;machine $machine login $user password $pass&quot; &gt; ~/.netrc
391 </command>
392         </hudson.tasks.Shell>
393         <hudson.tasks.Shell>
394           <command>#!/bin/bash
395 # SPDX-License-Identifier: EPL-1.0
396 ##############################################################################
397 # Copyright (c) 2017 The Linux Foundation and others.
398 #
399 # All rights reserved. This program and the accompanying materials
400 # are made available under the terms of the Eclipse Public License v1.0
401 # which accompanies this distribution, and is available at
402 # http://www.eclipse.org/legal/epl-v10.html
403 ##############################################################################
404 echo &quot;---&gt; lftools-install.sh&quot;
405
406 # By default a released version of lftools should always be used.
407 # The purpose of the 2 variables below is so that lftools devs can test
408 # unreleased versions of lftools. There are 2 methods to install a dev version
409 # of lftools:
410 #
411 #     1) gerrit patch: Used to test a patch that has not yet been merged.
412 #                      To do this set something like this:
413 #                          LFTOOLS_MODE=gerrit
414 #                          LFTOOLS_REFSPEC=refs/changes/96/5296/7
415 #
416 #     2) git branch: Used to install an lftools version from a specific branch.
417 #                    To use this set the variables as follows:
418 #                          LFTOOLS_MODE=git
419 #                          LFTOOLS_REFSPEC=master
420 #
421 #     3) release : The intended use case and default setting.
422 #                  Set LFTOOLS_MODE=release, in this case LFTOOLS_REFSPEC is unused.
423
424 LFTOOLS_MODE=release  # release | git | gerrit
425 LFTOOLS_REFSPEC=master
426
427 # Ensure we fail the job if any steps fail.
428 # DO NOT set -u as virtualenv's activate script has unbound variables
429 set -e -o pipefail
430
431 virtualenv --quiet &quot;/tmp/v/lftools&quot;
432 # shellcheck source=/tmp/v/lftools/bin/activate disable=SC1091
433 source &quot;/tmp/v/lftools/bin/activate&quot;
434 pip install --quiet --upgrade pip
435
436 case $LFTOOLS_MODE in
437     gerrit)
438         git clone https://gerrit.linuxfoundation.org/infra/releng/lftools.git /tmp/lftools
439         pushd /tmp/lftools
440         git fetch origin &quot;$LFTOOLS_REFSPEC&quot;
441         git checkout FETCH_HEAD
442         pip install --quiet --upgrade -r requirements.txt
443         pip install --quiet --upgrade -e .
444         popd
445         ;;
446
447     git)
448         pip install --quiet --upgrade git+https://gerrit.linuxfoundation.org/infra/releng/lftools.git@&quot;$BRANCH&quot;
449         ;;
450
451     release)
452         pip install --quiet --upgrade &quot;lftools&lt;1.0.0&quot;
453         ;;
454 esac
455
456 # pipdeptree prints out a lot of information because lftools pulls in many
457 # dependencies. Let's only print it if we want to debug.
458 # echo &quot;----&gt; Pip Dependency Tree&quot;
459 # pip install --quiet --upgrade pipdeptree
460 # pipdeptree
461
462 #!/bin/bash
463 # SPDX-License-Identifier: EPL-1.0
464 ##############################################################################
465 # Copyright (c) 2017 The Linux Foundation and others.
466 #
467 # All rights reserved. This program and the accompanying materials
468 # are made available under the terms of the Eclipse Public License v1.0
469 # which accompanies this distribution, and is available at
470 # http://www.eclipse.org/legal/epl-v10.html
471 ##############################################################################
472 echo &quot;---&gt; logs-deploy.sh&quot;
473
474 # Ensure we fail the job if any steps fail.
475 set -eu -o pipefail
476
477 set -x  # Trace commands for this script to make debugging easier.
478
479 ARCHIVE_ARTIFACTS=&quot;${ARCHIVE_ARTIFACTS:-}&quot;
480 LOGS_SERVER=&quot;${LOGS_SERVER:-None}&quot;
481
482 if [ &quot;${LOGS_SERVER}&quot; == 'None' ]
483 then
484     set +x # Disable trace since we no longer need it
485
486     echo &quot;WARNING: Logging server not set&quot;
487 else
488     NEXUS_URL=&quot;${NEXUS_URL:-$NEXUSPROXY}&quot;
489     NEXUS_PATH=&quot;${SILO}/${JENKINS_HOSTNAME}/${JOB_NAME}/${BUILD_NUMBER}&quot;
490     BUILD_URL=&quot;${BUILD_URL}&quot;
491
492     lftools deploy archives -p &quot;$ARCHIVE_ARTIFACTS&quot; &quot;$NEXUS_URL&quot; &quot;$NEXUS_PATH&quot; &quot;$WORKSPACE&quot;
493     lftools deploy logs &quot;$NEXUS_URL&quot; &quot;$NEXUS_PATH&quot; &quot;$BUILD_URL&quot;
494
495     set +x  # Disable trace since we no longer need it.
496
497     echo &quot;Build logs: &lt;a href=\&quot;$LOGS_SERVER/$NEXUS_PATH\&quot;&gt;$LOGS_SERVER/$NEXUS_PATH&lt;/a&gt;&quot;
498 fi
499 </command>
500         </hudson.tasks.Shell>
501         <hudson.tasks.Shell>
502           <command>#!/bin/bash
503 # SPDX-License-Identifier: EPL-1.0
504 ##############################################################################
505 # Copyright (c) 2017 The Linux Foundation and others.
506 #
507 # All rights reserved. This program and the accompanying materials
508 # are made available under the terms of the Eclipse Public License v1.0
509 # which accompanies this distribution, and is available at
510 # http://www.eclipse.org/legal/epl-v10.html
511 ##############################################################################
512
513 # Clear log credential files
514 rm &quot;$SETTINGS_FILE&quot;
515 rm ~/.netrc
516 </command>
517         </hudson.tasks.Shell>
518         <hudson.plugins.descriptionsetter.DescriptionSetterBuilder>
519           <regexp>^Build logs: .*</regexp>
520         </hudson.plugins.descriptionsetter.DescriptionSetterBuilder>
521       </buildSteps>
522       <scriptOnlyIfSuccess>false</scriptOnlyIfSuccess>
523       <scriptOnlyIfFailure>false</scriptOnlyIfFailure>
524       <markBuildUnstable>false</markBuildUnstable>
525     </org.jenkinsci.plugins.postbuildscript.PostBuildScript>
526     <hudson.plugins.ws__cleanup.WsCleanup plugin="ws-cleanup">
527       <patterns>
528         <hudson.plugins.ws__cleanup.Pattern>
529           <pattern>**/*.jenkins-trigger</pattern>
530           <type>EXCLUDE</type>
531         </hudson.plugins.ws__cleanup.Pattern>
532       </patterns>
533       <deleteDirs>false</deleteDirs>
534       <cleanupMatrixParent>false</cleanupMatrixParent>
535       <externalDelete/>
536       <cleanWhenSuccess>true</cleanWhenSuccess>
537       <cleanWhenUnstable>true</cleanWhenUnstable>
538       <cleanWhenFailure>true</cleanWhenFailure>
539       <cleanWhenNotBuilt>true</cleanWhenNotBuilt>
540       <cleanWhenAborted>true</cleanWhenAborted>
541       <notFailBuild>true</notFailBuild>
542     </hudson.plugins.ws__cleanup.WsCleanup>
543   </publishers>
544   <buildWrappers>
545     <com.michelin.cio.hudson.plugins.maskpasswords.MaskPasswordsBuildWrapper/>
546     <hudson.plugins.build__timeout.BuildTimeoutWrapper>
547       <timeoutMinutes>10</timeoutMinutes>
548       <timeoutEnvVar>BUILD_TIMEOUT</timeoutEnvVar>
549       <failBuild>true</failBuild>
550       <writingDescription>false</writingDescription>
551       <timeoutPercentage>0</timeoutPercentage>
552       <timeoutMinutesElasticDefault>3</timeoutMinutesElasticDefault>
553       <timeoutType>absolute</timeoutType>
554     </hudson.plugins.build__timeout.BuildTimeoutWrapper>
555     <hudson.plugins.timestamper.TimestamperBuildWrapper/>
556     <com.cloudbees.jenkins.plugins.sshagent.SSHAgentBuildWrapper>
557       <user>test-credential</user>
558     </com.cloudbees.jenkins.plugins.sshagent.SSHAgentBuildWrapper>
559     <jenkins.plugins.openstack.compute.JCloudsOneOffSlave/>
560   </buildWrappers>
561 </project>