2 name: integration-branch
7 description: 'Distribution GIT branch'
10 name: integration-bundleurl
14 default: '{bundleurl}'
15 description: 'URL to karaf distribution zip'
18 name: integration-jdk-version
22 default: '{jdkversion}'
23 description: 'Parameter to indicate JAVA Version'
26 name: integration-controller-scope
30 default: '{controller-scope}'
31 description: 'Feature Only or Feature All test'
34 name: integration-controller-features
37 name: CONTROLLERFEATURES
38 default: '{controller-features}'
39 description: 'Features to install in the controller separated by comma'
42 name: integration-distribution-stream
47 description: 'Distribution stream string, for suites to know which behavior to expect'
50 name: integration-stream-test-plan
54 default: '{stream-test-plan}'
55 description: 'Stream-specific test plan we will run'
58 name: integration-test-plan
62 default: '{test-plan}'
63 description: 'General test plan we will run unless stream-specific one is found'
66 name: integration-test-options
70 default: '{test-options}'
71 description: 'Robot command options'
74 name: integration-distribution-git-url
78 default: '{git-url}/integration/distribution'
79 description: 'Distribution GIT URL (do not modify)'
82 name: integration-patch-refspec
87 description: 'Integration Patch Refspec'
89 # Macro: integration-gerrit-scm
90 # Operation: this macro downloads a project gerrit
91 # Used by: all csit jobs
94 name: integration-gerrit-scm
97 credentials-id: 'opendaylight-jenkins-ssh'
104 choosing-strategy: 'gerrit'
106 # Macro: integration-distribution-scm
107 # Operation: this macro downloads the integration/distribution repo using distribution as basedir
108 # Used by: integration-patch-test-{stream} job template
111 name: integration-distribution-scm
114 credentials-id: 'opendaylight-jenkins-ssh'
115 basedir: 'distribution'
122 # Macro: integration-trigger-patch-submitted
123 # This is a single macro to use for all csit jobs who vote on every (relevant) patch set.
124 # Only 'recheck' trigger word is supported, it always triggers the full set of relevant jobs,
125 # in order to prevent Jenkins from starting only a subset and still voting Verified+1.
126 # Contrary to gerrit-trigger-patch-submitted, this votes +1 also on unstable runs.
128 # server: name of gerrit server to listen to
129 # project: pattern to match triggering projects
130 # branch: triggering branch name
131 # files: pattern to match triggering filepaths
133 name: integration-trigger-patch-submitted
136 server-name: '{server}'
138 - patchset-created-event:
139 exclude-drafts: 'true'
140 exclude-trivial-rebase: 'false'
141 exclude-no-code-change: 'true'
142 - draft-published-event
143 - comment-added-contains-event:
144 comment-contains-value: 'recheck'
146 gerrit-build-unstable-verified-value: +1
147 gerrit-build-unstable-codereview-value: 0
149 - project-compare-type: 'ANT'
150 project-pattern: '{project}'
152 - branch-compare-type: 'ANT'
153 branch-pattern: '**/{branch}'
155 - compare-type: 'ANT'
158 # Macro: integration-openstack-controller-mininet
159 # Operation: this macro will spin the controller and mininet vms
160 # Used by: {project}-csit-* job templates
163 name: integration-openstack-controller-mininet
167 - cloud-name: 'ODLRPC'
168 template-name: '{controller-image}'
169 count: '{controller-vms}'
170 - cloud-name: 'ODLRPC'
171 template-name: '{mininet-image}'
172 count: '{mininet-vms}'
174 # Macro: integration-openstack-controller-devstack
175 # Operation: this macro will spin the controller and devstack vms
176 # Used by: {project}-csit-openstack job templates
178 name: integration-openstack-controller-devstack
182 - cloud-name: 'ODLRPC'
183 template-name: '{controller-image}'
184 count: '{controller-vms}'
185 - cloud-name: 'ODLRPC'
186 template-name: '{openstack-image}'
187 count: '{openstack-vms}'
193 # Macro: integration-infra-stack
194 # Operation: Sets environment and then calls opendaylight-infra-stack to spin
195 # up csit lab using openstack-heat.
196 # Used by: {project}-csit-* job templates
199 name: integration-infra-stack
201 - integration-cleanup-workspace
204 # Setup openstack envirnoment file for use by
205 # the opendaylight-infra-stack macro
206 cat > $WORKSPACE/opendaylight-infra-environment.yaml << EOF
208 vm_0_count: {vm_0_count}
209 vm_0_flavor: {vm_0_flavor}
210 vm_0_image: {vm_0_image}
211 vm_1_count: {vm_1_count}
212 vm_1_flavor: {vm_1_flavor}
213 vm_1_image: {vm_1_image}
215 echo "Contents of opendaylight-infra-environment.yaml ..."
216 cat $WORKSPACE/opendaylight-infra-environment.yaml
217 - opendaylight-infra-stack:
218 stack-template: '{stack-template}'
220 # Macro: integration-infra-stack-3-type
221 # Operation: Sets environment and then calls opendaylight-infra-stack to spin
222 # up csit lab using openstack-heat.
223 # Used by: {project}-csit-* job templates
226 name: integration-infra-stack-3-type
228 - integration-cleanup-workspace
231 # Setup openstack envirnoment file for use by
232 # the opendaylight-infra-stack macro
233 cat > $WORKSPACE/opendaylight-infra-environment.yaml << EOF
235 vm_0_count: {vm_0_count}
236 vm_0_flavor: {vm_0_flavor}
237 vm_0_image: {vm_0_image}
238 vm_1_count: {vm_1_count}
239 vm_1_flavor: {vm_1_flavor}
240 vm_1_image: {vm_1_image}
241 vm_2_count: {vm_2_count}
242 vm_2_flavor: {vm_2_flavor}
243 vm_2_image: {vm_2_image}
245 echo "Contents of opendaylight-infra-environment.yaml ..."
246 cat $WORKSPACE/opendaylight-infra-environment.yaml
247 - opendaylight-infra-stack:
248 stack-template: 'csit-3-instance-type.yaml'
250 # Macro: integration-get-slave-addresses
251 # Operation: this macro gets the IP addresses of the dynamic vms
252 # Used by: {project}-csit-* job templates
255 name: integration-get-slave-addresses
259 - include-raw-integration-get-slave-addresses.sh
261 # Macro: integration-get-bundle-vars
262 # Operation: this macro gets all bundle related variables
263 # Used by: {project}-csit-3node-* job templates
266 name: integration-get-bundle-vars
270 - include-raw-integration-get-bundle-vars.sh
272 # Macro: integration-distribution-check
273 # Operation: this macro deploys the controller with all fetures
274 # Used by: {project}-distribution-check-{stream} job template
277 name: integration-distribution-check
281 - include-raw-integration-distribution-check.sh
283 # Macro: integration-deploy-controller-verify
284 # Operation: this macro deploys the controller with all fetures
285 # Used by: distribution-deploy-{stream} job template
288 name: integration-deploy-controller-verify
292 - include-raw-integration-deploy-controller-verify.sh
294 # Macro: integration-deploy-controller-offline
295 # Operation: this macro deploys the controller with no external repo configuration
296 # Used by: integration-distrbution-offline-{stream} job template
299 name: integration-deploy-controller-offline
303 - include-raw-integration-deploy-controller-offline.sh
305 # Macro: integration-deply-controller-run-test
306 # Operation: this macro deploys single contoller and runs test
307 # Used by: {project}-csit-1node-* job templates
310 name: integration-deploy-controller-run-test
314 - include-raw-integration-deploy-controller-run-test.sh
316 # Macro: integration-configure-clustering
317 # Operation: this macro configures the clustering
318 # Used by: {project}-csit-3node-* job templates
321 name: integration-configure-clustering
325 - include-raw-integration-configure-clustering.sh
327 # Macro: integration-start-cluster-run-test
328 # Operation: this macro starts the 3-node cluster and runs test
329 # Used by: {project}-csit-3node-* job templates
332 name: integration-start-cluster-run-test
336 - include-raw-integration-start-cluster-run-test.sh
338 # Macro: integration-get-bundle-url
339 # Operation: this macro gets the job generated distribution URL from distribution pom.xml
340 # Used by: integration-patch-test-{stream} job template
343 name: integration-get-bundle-url
347 - include-raw-integration-get-bundle-url.sh
349 # Macro: integration-get-bundle-url-root
350 # Operation: this macro gets the job generated distribution URL from root pom.xml
351 # Used by: distribution-verify-{stream} job template
354 name: integration-get-bundle-url-root
358 - include-raw-integration-get-bundle-url-root.sh
360 # Macro: integration-install-robotframework
361 # Operation: Installs robotframework using pip to a virtualenv
362 # Used by: {project}-csit-* job templates
365 name: integration-install-robotframework
369 - include-raw-integration-install-robotframework.sh
371 # Macro: integration-cleanup-tmp
372 # Operation: Cleans up temporary files created by build
373 # Used by: {project}-csit-* job templates
376 name: integration-cleanup-tmp
380 - include-raw-integration-cleanup-tmp.sh
382 # Macro: integration-multipatch-builder
383 # Operation: checks out multiple patches and builds custom distribution
384 # Used by: integration-multipatch-test-* job templates
387 name: integration-multipatch-builder
391 - include-raw-integration-multipatch-distribution-test.sh
393 # Macro: integration-cleanup-workspace
394 # Operation: Cleans up files possibly left there by the previous build
395 # Used by: {project}-csit-* job templates
398 name: integration-cleanup-workspace
402 - include-raw-integration-cleanup-workspace.sh
404 # Macro: integration-rebase-patch
405 # Operation: For cloned project, rebase checked-out Gerrit patch onto $BRANCH.
406 # Used by: integration-patch-distribution-* job template
409 name: integration-rebase-gerrit-patch
413 - include-raw-integration-rebase-gerrit-patch.sh
416 name: integration-deploy-openstack-run-test
420 - include-raw-integration-deploy-openstack-run-test.sh
422 # Macro: integration-list-jobs
423 # Operation: queries Jenkins jobs from jenkins.opendaylight.org and
424 # writes a list of the jobs corresponding to the search terms to a file.
425 # Used by: builder-merge job template
427 # This script requires the following JJB variables to be passed in:
428 # {search_string} Job type to act as a primary filter (e.g. csit)
429 # {blacklist} List of sub-projects to filter out (e.g. longevity)
430 # {stream} Development release name (e.g. boron)
431 # {jobs-filename} Filename to write list into (e.g. carbon-jobs.lst)
432 # NOTE: Requires xmlstarlet installed on node.
435 name: integration-list-jobs
439 - include-raw-integration-list-jobs.sh
441 # Macro: integration-replace-block-text
442 # Operation: using starting and ending regex to
443 # replace a block of text in a file with the text in
444 # another file. Regex should be basic and work with sed
445 # Used by: builder-merge job template
447 # This script requires the following JJB variables to be passed in:
450 # {file-with-changes-to-insert}
454 name: integration-replace-block-text
458 - include-raw-integration-replace-block-text.sh
460 # Macro: integration-compare-distributions
461 # Operation: will compare an already created distribtion (probably last
462 # published to nexus) to the current distribution being created.
463 # The comparison is done to find the list of patches that are new to the
464 # current distribtion.
465 # Used by: builder-merge job template
467 # This script requires the bundle vars that are created by the
468 # get-bundle-vars macro script
472 name: integration-compare-distributions
476 - include-raw-integration-compare-distributions.sh
482 # Macro: integration-robot
483 # Operation: this macro publishes robot results
484 # Used by: {project}-csit-* job templates
487 name: integration-robot
492 unstable-threshold: '{unstable-if}'
493 pass-threshold: '{pass-if}'
497 name: integration-robot-tempest
502 - tempest_results.html
503 unstable-threshold: '{unstable-if}'
504 pass-threshold: '{pass-if}'
508 name: integration-csit-archive-build
514 mkdir -p $WORKSPACE/archives
515 curl --output robot-plugin.zip "$BUILD_URL/robot/report/*zip*/robot-plugin.zip"
516 unzip -d $WORKSPACE/archives robot-plugin.zip
517 mv *log* *.log *.log.gz *.csv *.png $WORKSPACE/archives || true # Don't fail if file missing
518 script-only-if-succeeded: False
519 script-only-if-failed: False
520 mark-unstable-if-failed: True