Apex: fix daily scm passing and yardstick deploy blocking
[releng.git] / jjb / apex / apex.yml.j2
1 - project:
2     name: 'apex'
3     project: 'apex'
4     jobs:
5         - 'apex-verify-{stream}'
6         - 'apex-verify-gate-{stream}'
7         - 'apex-verify-unit-tests-{stream}'
8         - 'apex-runner-cperf-{stream}'
9         - 'apex-build-{stream}'
10         - 'apex-deploy-{platform}-{stream}'
11         - 'apex-daily-master'
12         - 'apex-daily-danube'
13         - 'apex-csit-promote-daily-{stream}'
14         - 'apex-fdio-promote-daily-{stream}'
15         - 'apex-verify-iso-{stream}'
16         - 'apex-deploy-test-baremetal-{stream}'
17         - 'apex-upload-snapshot'
18         - 'apex-create-snapshot'
19     # stream:    branch with - in place of / (eg. stable-arno)
20     # branch:    branch (eg. stable/arno)
21     stream:
22         - master:
23             branch: 'master'
24             gs-pathname: ''
25             build-slave: 'apex-build-master'
26             virtual-slave: 'apex-virtual-master'
27             baremetal-slave: 'apex-baremetal-master'
28             verify-scenario: 'os-odl-nofeature-ha'
29
30         - danube:
31             branch: 'stable/danube'
32             gs-pathname: '/danube'
33             build-slave: 'apex-build-danube'
34             virtual-slave: 'apex-virtual-danube'
35             baremetal-slave: 'apex-baremetal-danube'
36             verify-scenario: 'os-odl_l3-nofeature-ha'
37             disabled: false
38
39     platform:
40          - 'baremetal'
41          - 'virtual'
42
43 # Unit Test
44 - job-template:
45     name: 'apex-verify-unit-tests-{stream}'
46
47     node: '{build-slave}'
48
49     concurrent: true
50
51     parameters:
52         - apex-parameter:
53             gs-pathname: '{gs-pathname}'
54         - project-parameter:
55             project: '{project}'
56             branch: '{branch}'
57
58     scm:
59         - git-scm-gerrit
60
61     triggers:
62         - gerrit:
63             server-name: 'gerrit.opnfv.org'
64             trigger-on:
65                 - patchset-created-event:
66                     exclude-drafts: 'false'
67                     exclude-trivial-rebase: 'false'
68                     exclude-no-code-change: 'true'
69                 - draft-published-event
70                 - comment-added-contains-event:
71                     comment-contains-value: 'recheck'
72                 - comment-added-contains-event:
73                     comment-contains-value: 'reverify'
74             projects:
75               - project-compare-type: 'ANT'
76                 project-pattern: 'apex'
77                 branches:
78                   - branch-compare-type: 'ANT'
79                     branch-pattern: '**/{branch}'
80                 file-paths:
81                   - compare-type: ANT
82                     pattern: 'tests/**'
83     properties:
84         - logrotate-default
85         - throttle:
86             max-per-node: 1
87             max-total: 10
88             option: 'project'
89
90     builders:
91         - shell:
92             !include-raw-escape: ./apex-unit-test.sh
93
94 # Verify
95 - job-template:
96     name: 'apex-verify-{stream}'
97
98     node: '{virtual-slave}'
99
100     concurrent: true
101
102     project-type: 'multijob'
103
104     parameters:
105         - apex-parameter:
106             gs-pathname: '{gs-pathname}/dev'
107         - project-parameter:
108             project: '{project}'
109             branch: '{branch}'
110         - string:
111             name: ARTIFACT_VERSION
112             default: dev
113             description: "Used for overriding the ARTIFACT_VERSION"
114     scm:
115         - git-scm-gerrit
116
117     triggers:
118         - gerrit:
119             server-name: 'gerrit.opnfv.org'
120             trigger-on:
121                 - patchset-created-event:
122                     exclude-drafts: 'false'
123                     exclude-trivial-rebase: 'false'
124                     exclude-no-code-change: 'true'
125                 - draft-published-event
126                 - comment-added-contains-event:
127                     comment-contains-value: 'recheck'
128                 - comment-added-contains-event:
129                     comment-contains-value: 'reverify'
130             projects:
131               - project-compare-type: 'ANT'
132                 project-pattern: 'apex'
133                 branches:
134                   - branch-compare-type: 'ANT'
135                     branch-pattern: '**/{branch}'
136                 file-paths:
137                   - compare-type: ANT
138                     pattern: 'ci/**'
139                   - compare-type: ANT
140                     pattern: 'build/**'
141                   - compare-type: ANT
142                     pattern: 'lib/**'
143                   - compare-type: ANT
144                     pattern: 'config/**'
145
146     properties:
147         - logrotate-default
148         - build-blocker:
149             use-build-blocker: true
150             block-level: 'NODE'
151             blocking-jobs:
152                 - 'apex-daily.*'
153                 - 'apex-deploy.*'
154                 - 'apex-runner.*'
155         - throttle:
156             max-per-node: 3
157             max-total: 10
158             option: 'project'
159
160     builders:
161         - description-setter:
162             description: "Built on $NODE_NAME"
163         - multijob:
164             name: basic
165             condition: SUCCESSFUL
166             projects:
167                 - name: 'apex-verify-unit-tests-{stream}'
168                   current-parameters: false
169                   predefined-parameters: |
170                     GERRIT_BRANCH=$GERRIT_BRANCH
171                     GERRIT_REFSPEC=$GERRIT_REFSPEC
172                     GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
173                     GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
174                   node-parameters: false
175                   kill-phase-on: FAILURE
176                   abort-all-job: true
177                   git-revision: true
178         - multijob:
179             name: build
180             condition: SUCCESSFUL
181             projects:
182                 - name: 'apex-build-{stream}'
183                   current-parameters: false
184                   predefined-parameters: |
185                     ARTIFACT_VERSION=$ARTIFACT_VERSION
186                     GERRIT_BRANCH=$GERRIT_BRANCH
187                     GERRIT_REFSPEC=$GERRIT_REFSPEC
188                     GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
189                     GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
190                   node-parameters: false
191                   kill-phase-on: FAILURE
192                   abort-all-job: true
193                   git-revision: true
194         - multijob:
195             name: deploy-virtual
196             condition: SUCCESSFUL
197             projects:
198                 - name: 'apex-deploy-virtual-{stream}'
199                   current-parameters: false
200                   predefined-parameters: |
201                     ARTIFACT_VERSION=$ARTIFACT_VERSION
202                     DEPLOY_SCENARIO={verify-scenario}
203                     OPNFV_CLEAN=yes
204                     GERRIT_BRANCH=$GERRIT_BRANCH
205                     GERRIT_REFSPEC=$GERRIT_REFSPEC
206                     GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
207                     GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
208                   node-parameters: true
209                   kill-phase-on: FAILURE
210                   abort-all-job: true
211                   git-revision: true
212         - multijob:
213             name: functest-smoke
214             condition: SUCCESSFUL
215             projects:
216               - name: 'functest-apex-virtual-suite-{stream}'
217                 current-parameters: false
218                 predefined-parameters: |
219                   DEPLOY_SCENARIO={verify-scenario}
220                   FUNCTEST_SUITE_NAME=healthcheck
221                   GERRIT_BRANCH=$GERRIT_BRANCH
222                   GERRIT_REFSPEC=$GERRIT_REFSPEC
223                   GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
224                   GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
225                 node-parameters: true
226                 kill-phase-on: FAILURE
227                 abort-all-job: true
228                 git-revision: false
229
230 # Verify Scenario Gate
231 - job-template:
232     name: 'apex-verify-gate-{stream}'
233
234     node: '{virtual-slave}'
235
236     concurrent: true
237
238     project-type: 'multijob'
239
240     parameters:
241         - apex-parameter:
242             gs-pathname: '{gs-pathname}/dev'
243         - project-parameter:
244             project: '{project}'
245             branch: '{branch}'
246         - string:
247             name: GIT_BASE
248             default: https://gerrit.opnfv.org/gerrit/$PROJECT
249             description: "Used for overriding the GIT URL coming from parameters macro."
250         - string:
251             name: ARTIFACT_VERSION
252             default: dev
253             description: "Used for overriding the ARTIFACT_VERSION"
254
255     scm:
256         - git-scm-gerrit
257
258     triggers:
259         - gerrit:
260             server-name: 'gerrit.opnfv.org'
261             trigger-on:
262                 - comment-added-contains-event:
263                     comment-contains-value: '^Patch Set [0-9]+: Code-Review\+2.*start-gate-scenario:.*'
264             projects:
265               - project-compare-type: 'ANT'
266                 project-pattern: 'apex'
267                 branches:
268                   - branch-compare-type: 'ANT'
269                     branch-pattern: '**/{branch}'
270                 file-paths:
271                   - compare-type: ANT
272                     pattern: 'ci/**'
273                   - compare-type: ANT
274                     pattern: 'build/**'
275                   - compare-type: ANT
276                     pattern: 'lib/**'
277                   - compare-type: ANT
278                     pattern: 'config/**'
279
280     properties:
281         - logrotate-default
282         - build-blocker:
283             use-build-blocker: true
284             block-level: 'NODE'
285             blocking-jobs:
286                 - 'apex-daily.*'
287                 - 'apex-deploy.*'
288                 - 'apex-runner.*'
289         - throttle:
290             max-per-node: 3
291             max-total: 10
292             option: 'project'
293
294     builders:
295         - multijob:
296             name: deploy-virtual
297             condition: SUCCESSFUL
298             projects:
299                 - name: 'apex-deploy-virtual-{stream}'
300                   current-parameters: false
301                   predefined-parameters: |
302                     ARTIFACT_VERSION=$ARTIFACT_VERSION
303                     DEPLOY_SCENARIO=gate
304                     OPNFV_CLEAN=yes
305                     GERRIT_BRANCH=$GERRIT_BRANCH
306                     GERRIT_REFSPEC=$GERRIT_REFSPEC
307                     GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
308                     GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
309                   node-parameters: true
310                   kill-phase-on: FAILURE
311                   abort-all-job: true
312                   git-revision: true
313         - multijob:
314             name: functest-smoke
315             condition: SUCCESSFUL
316             projects:
317               - name: 'functest-apex-virtual-suite-{stream}'
318                 current-parameters: false
319                 predefined-parameters: |
320                   DEPLOY_SCENARIO={verify-scenario}
321                   FUNCTEST_SUITE_NAME=healthcheck
322                   GERRIT_BRANCH=$GERRIT_BRANCH
323                   GERRIT_REFSPEC=$GERRIT_REFSPEC
324                   GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
325                   GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
326                 node-parameters: true
327                 kill-phase-on: FAILURE
328                 abort-all-job: true
329                 git-revision: false
330
331 - job-template:
332     name: 'apex-runner-cperf-{stream}'
333
334     # runner cperf job
335     project-type: 'multijob'
336     node: 'intel-pod2'
337
338     disabled: false
339
340     parameters:
341         - apex-parameter:
342             gs-pathname: '{gs-pathname}'
343         - project-parameter:
344             project: '{project}'
345             branch: '{branch}'
346         - string:
347             name: GIT_BASE
348             default: https://gerrit.opnfv.org/gerrit/$PROJECT
349             description: "Used for overriding the GIT URL coming from parameters macro."
350
351     scm:
352         - git-scm
353
354     properties:
355         - logrotate-default
356         - build-blocker:
357             use-build-blocker: false
358             block-level: 'NODE'
359             blocking-jobs:
360                 - 'apex-deploy.*'
361         - throttle:
362             max-per-node: 1
363             max-total: 10
364             option: 'project'
365
366     builders:
367         - description-setter:
368             description: "Deployed on $NODE_NAME"
369         - multijob:
370             name: 'Baremetal Deploy'
371             condition: ALWAYS
372             projects:
373                 - name: 'apex-deploy-baremetal-{stream}'
374                   node-parameters: false
375                   current-parameters: true
376                   predefined-parameters: |
377                     OPNFV_CLEAN=yes
378                     DEPLOY_SCENARIO={verify-scenario}
379                   kill-phase-on: FAILURE
380                   abort-all-job: true
381                   git-revision: false
382         - multijob:
383             name: Functest
384             condition: ALWAYS
385             projects:
386                 - name: 'functest-apex-baremetal-daily-{stream}'
387                   node-parameters: true
388                   current-parameters: false
389                   predefined-parameters:
390                     DEPLOY_SCENARIO={verify-scenario}
391                   kill-phase-on: NEVER
392                   abort-all-job: false
393                   git-revision: false
394
395 # Build phase
396 - job-template:
397     name: 'apex-build-{stream}'
398
399     # Job template for builds
400     #
401     # Required Variables:
402     #     stream:    branch with - in place of / (eg. stable)
403     #     branch:    branch (eg. stable)
404     node: '{build-slave}'
405
406     disabled: false
407
408     concurrent: true
409
410     parameters:
411         - '{project}-defaults'
412         - project-parameter:
413             project: '{project}'
414             branch: '{branch}'
415         - apex-parameter:
416             gs-pathname: '{gs-pathname}'
417
418     scm:
419         - git-scm-gerrit
420
421     wrappers:
422         - timeout:
423             timeout: 90
424             fail: true
425
426     properties:
427         - logrotate-default
428         - throttle:
429             max-per-node: 3
430             max-total: 10
431             option: 'project'
432
433     builders:
434         - 'apex-build'
435         - inject:
436            properties-content: ARTIFACT_TYPE=rpm
437         - 'apex-upload-artifact'
438
439 # ISO verify job
440 - job-template:
441     name: 'apex-verify-iso-{stream}'
442
443     # Job template for builds
444     #
445     # Required Variables:
446     #     stream:    branch with - in place of / (eg. stable)
447     #     branch:    branch (eg. stable)
448     node: '{virtual-slave}'
449
450     disabled: false
451
452     concurrent: true
453
454     parameters:
455         - project-parameter:
456             project: '{project}'
457             branch: '{branch}'
458         - apex-parameter:
459             gs-pathname: '{gs-pathname}'
460         - string:
461             name: GIT_BASE
462             default: https://gerrit.opnfv.org/gerrit/$PROJECT
463             description: "Used for overriding the GIT URL coming from parameters macro."
464
465     scm:
466         - git-scm
467
468     properties:
469         - logrotate-default
470         - build-blocker:
471             use-build-blocker: true
472             block-level: 'NODE'
473             blocking-jobs:
474                 - 'apex-deploy.*'
475         - throttle:
476             max-per-node: 1
477             max-total: 10
478             option: 'project'
479
480     builders:
481         - 'apex-iso-verify'
482         - inject:
483            properties-content: ARTIFACT_TYPE=iso
484         - 'apex-upload-artifact'
485
486 # Deploy job
487 - job-template:
488     name: 'apex-deploy-{platform}-{stream}'
489
490     # Job template for virtual deployment
491     #
492     # Required Variables:
493     #     stream:    branch with - in place of / (eg. stable)
494     #     branch:    branch (eg. stable)
495     node: 'apex-{platform}-{stream}'
496
497     concurrent: true
498
499     disabled: false
500
501     scm:
502         - git-scm-gerrit
503
504     wrappers:
505         - timeout:
506             timeout: 120
507             fail: true
508
509     parameters:
510         - project-parameter:
511             project: '{project}'
512             branch: '{branch}'
513         - apex-parameter:
514             gs-pathname: '{gs-pathname}'
515         - string:
516             name: DEPLOY_SCENARIO
517             default: '{verify-scenario}'
518             description: "Scenario to deploy with."
519         - string:
520             name: OPNFV_CLEAN
521             default: 'no'
522             description: "Use yes in lower case to invoke clean. Indicates if the deploy environment should be cleaned before deployment"
523
524     properties:
525         - logrotate-default
526         - build-blocker:
527             use-build-blocker: true
528             block-level: 'NODE'
529             blocking-jobs:
530                 - 'apex-deploy.*'
531                 - 'functest.*'
532                 - 'yardstick.*'
533         - throttle:
534             max-per-node: 1
535             max-total: 10
536             option: 'project'
537
538     builders:
539         - description-setter:
540             description: "Deployed on $NODE_NAME - Scenario: $DEPLOY_SCENARIO"
541         - 'apex-download-artifact'
542         - 'apex-deploy'
543         - 'apex-workspace-cleanup'
544
545
546 # Baremetal Deploy and Test
547 - job-template:
548     name: 'apex-deploy-test-baremetal-{stream}'
549
550     # Job template for daily build
551     #
552     # Required Variables:
553     #     stream:    branch with - in place of / (eg. stable)
554     #     branch:    branch (eg. stable)
555     project-type: 'multijob'
556
557     disabled: false
558
559     scm:
560         - git-scm
561
562     parameters:
563         - '{project}-defaults'
564         - '{project}-baremetal-{stream}-defaults'
565         - project-parameter:
566             project: '{project}'
567             branch: '{branch}'
568         - apex-parameter:
569             gs-pathname: '{gs-pathname}'
570         - string:
571             name: DEPLOY_SCENARIO
572             default: '{verify-scenario}'
573             description: "Scenario to deploy with."
574     properties:
575         - logrotate-default
576         - build-blocker:
577             use-build-blocker: true
578             block-level: 'NODE'
579             blocking-jobs:
580                 - 'apex-verify.*'
581                 - 'apex-deploy.*'
582                 - 'apex-runner.*'
583                 - 'apex-.*-promote.*'
584     builders:
585         - description-setter:
586             description: "Deployed on $NODE_NAME - Scenario: $DEPLOY_SCENARIO"
587         - multijob:
588             name: 'Baremetal Deploy'
589             condition: ALWAYS
590             projects:
591                 - name: 'apex-deploy-baremetal-{stream}'
592                   node-parameters: true
593                   current-parameters: true
594                   predefined-parameters: |
595                     OPNFV_CLEAN=yes
596                   kill-phase-on: FAILURE
597                   abort-all-job: true
598                   git-revision: false
599         - multijob:
600             name: Functest
601             condition: ALWAYS
602             projects:
603                 - name: 'functest-apex-baremetal-daily-{stream}'
604                   node-parameters: true
605                   current-parameters: false
606                   predefined-parameters:
607                     DEPLOY_SCENARIO=$DEPLOY_SCENARIO
608                   kill-phase-on: NEVER
609                   abort-all-job: false
610                   git-revision: false
611         - multijob:
612             name: Yardstick
613             condition: ALWAYS
614             projects:
615                 - name: 'yardstick-apex-baremetal-daily-{stream}'
616                   node-parameters: true
617                   current-parameters: false
618                   predefined-parameters:
619                     DEPLOY_SCENARIO=$DEPLOY_SCENARIO
620                   kill-phase-on: NEVER
621                   abort-all-job: false
622                   git-revision: false
623
624 {% for stream in scenarios %}
625 # {{ stream }} Daily
626 - job-template:
627     name: 'apex-daily-{{ stream }}'
628
629     # Job template for daily build
630     #
631     # Required Variables:
632     #     stream:    branch with - in place of / (eg. stable)
633     #     branch:    branch (eg. stable)
634     project-type: 'multijob'
635
636     node: '{{ build_slave[stream] }}'
637
638     disabled: false
639
640     scm:
641         - git-scm
642
643     parameters:
644         - '{project}-defaults'
645         - '{project}-baremetal-{{ stream }}-defaults'
646         - project-parameter:
647             project: '{project}'
648             branch: '{{ branch[stream] }}'
649         - apex-parameter:
650             gs-pathname: '{{ gspathname[stream] }}'
651
652     properties:
653         - logrotate-default
654
655     triggers:
656         - 'apex-{{ stream }}'
657
658     builders:
659         - multijob:
660             name: build
661             condition: SUCCESSFUL
662             projects:
663                 - name: 'apex-build-{{ stream }}'
664                   current-parameters: false
665                   predefined-parameters: |
666                     GERRIT_BRANCH=$GERRIT_BRANCH
667                     GERRIT_REFSPEC=''
668                     GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
669                     GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
670                   node-parameters: true
671                   kill-phase-on: FAILURE
672                   abort-all-job: true
673                   git-revision: true
674         - multijob:
675             name: 'Verify and upload ISO'
676             condition: SUCCESSFUL
677             projects:
678                 - name: 'apex-verify-iso-{{ stream }}'
679                   current-parameters: false
680                   predefined-parameters: |
681                     BUILD_DIRECTORY=apex-build-{{ stream }}/.build
682                     GERRIT_BRANCH=$GERRIT_BRANCH
683                     GERRIT_REFSPEC=''
684                     GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
685                     GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
686                   node-parameters: true
687                   kill-phase-on: FAILURE
688                   abort-all-job: true
689                   git-revision: true
690         - multijob:
691             name: Baremetal Deploy and Test Phase
692             condition: SUCCESSFUL
693             projects:
694 {% for scenario in scenarios[stream] %}
695                 - name: 'apex-deploy-test-baremetal-{{ stream }}'
696                   node-parameters: false
697                   current-parameters: false
698                   predefined-parameters: |
699                     DEPLOY_SCENARIO={{scenario}}
700                     OPNFV_CLEAN=yes
701                   kill-phase-on: NEVER
702                   abort-all-job: true
703                   git-revision: false
704 {% endfor %}
705 {% endfor %}
706
707 # snapshot create
708 - job-template:
709     name: 'apex-create-snapshot'
710
711     # Job template for clean
712     #
713     # Required Variables:
714     #     stream:    branch with - in place of / (eg. stable)
715
716     disabled: false
717
718     builders:
719         - shell:
720             !include-raw-escape: ./apex-snapshot-create.sh
721
722 # snapshot upload
723 - job-template:
724     name: 'apex-upload-snapshot'
725
726     # Job template for clean
727     #
728     # Required Variables:
729     #     stream:    branch with - in place of / (eg. stable)
730
731     disabled: false
732
733     builders:
734         - inject:
735            properties-content: ARTIFACT_TYPE=snapshot
736         - 'apex-upload-artifact'
737
738 # CSIT promote
739 - job-template:
740     name: 'apex-csit-promote-daily-{stream}'
741
742     # Job template for promoting CSIT Snapshots
743     #
744     # Required Variables:
745     #     stream:    branch with - in place of / (eg. stable)
746     #     branch:    branch (eg. stable)
747     node: '{virtual-slave}'
748     project-type: 'multijob'
749     disabled: false
750
751     scm:
752         - git-scm
753
754     parameters:
755         - project-parameter:
756             project: '{project}'
757             branch: '{branch}'
758         - apex-parameter:
759             gs-pathname: '{gs-pathname}'
760
761     properties:
762         - build-blocker:
763             use-build-blocker: true
764             block-level: 'NODE'
765             blocking-jobs:
766                 - 'apex-verify.*'
767                 - 'apex-deploy.*'
768                 - 'apex-runner.*'
769                 - 'apex-daily.*'
770
771     triggers:
772         - timed: '0 12 * * 0'
773
774     builders:
775         - multijob:
776             name: build
777             condition: SUCCESSFUL
778             projects:
779                 - name: 'apex-build-{stream}'
780                   current-parameters: false
781                   predefined-parameters: |
782                     GERRIT_BRANCH=$GERRIT_BRANCH
783                     GERRIT_REFSPEC=$GERRIT_REFSPEC
784                     GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
785                     GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
786                   node-parameters: false
787                   kill-phase-on: FAILURE
788                   abort-all-job: true
789                   git-revision: true
790         - multijob:
791             name: deploy-virtual
792             condition: SUCCESSFUL
793             projects:
794                 - name: 'apex-deploy-virtual-{stream}'
795                   current-parameters: false
796                   predefined-parameters: |
797                     DEPLOY_SCENARIO=os-odl_l3-csit-noha
798                     OPNFV_CLEAN=yes
799                     GERRIT_BRANCH=$GERRIT_BRANCH
800                     GERRIT_REFSPEC=$GERRIT_REFSPEC
801                     GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
802                     GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
803                   node-parameters: true
804                   kill-phase-on: FAILURE
805                   abort-all-job: true
806                   git-revision: false
807         - multijob:
808             name: functest-smoke
809             condition: SUCCESSFUL
810             projects:
811               - name: 'functest-apex-virtual-suite-{stream}'
812                 current-parameters: false
813                 predefined-parameters: |
814                   DEPLOY_SCENARIO=os-odl_l3-nofeature-noha
815                   FUNCTEST_SUITE_NAME=tempest_smoke_serial
816                   GERRIT_BRANCH=$GERRIT_BRANCH
817                   GERRIT_REFSPEC=$GERRIT_REFSPEC
818                   GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
819                   GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
820                 node-parameters: true
821                 kill-phase-on: FAILURE
822                 abort-all-job: true
823                 git-revision: false
824         - multijob:
825             name: create snapshot
826             condition: SUCCESSFUL
827             projects:
828               - name: 'apex-create-snapshot'
829                 current-parameters: true
830                 node-parameters: true
831                 kill-phase-on: FAILURE
832                 abort-all-job: true
833                 git-revision: false
834         - multijob:
835             name: upload snapshot
836             condition: SUCCESSFUL
837             projects:
838               - name: 'apex-upload-snapshot'
839                 current-parameters: true
840                 node-parameters: true
841                 kill-phase-on: FAILURE
842                 abort-all-job: true
843                 git-revision: false
844
845 # FDIO promote
846 - job-template:
847     name: 'apex-fdio-promote-daily-{stream}'
848
849     # Job template for promoting CSIT Snapshots
850     #
851     # Required Variables:
852     #     stream:    branch with - in place of / (eg. stable)
853     #     branch:    branch (eg. stable)
854     node: '{virtual-slave}'
855     project-type: 'multijob'
856     disabled: false
857
858     scm:
859         - git-scm
860
861     parameters:
862         - project-parameter:
863             project: '{project}'
864             branch: '{branch}'
865         - apex-parameter:
866             gs-pathname: '{gs-pathname}'
867
868     properties:
869         - build-blocker:
870             use-build-blocker: true
871             block-level: 'NODE'
872             blocking-jobs:
873                 - 'apex-verify.*'
874                 - 'apex-deploy.*'
875                 - 'apex-runner.*'
876                 - 'apex-daily.*'
877
878     builders:
879         - multijob:
880             name: build
881             condition: SUCCESSFUL
882             projects:
883                 - name: 'apex-build-{stream}'
884                   current-parameters: false
885                   predefined-parameters: |
886                     GERRIT_BRANCH=$GERRIT_BRANCH
887                     GERRIT_REFSPEC=$GERRIT_REFSPEC
888                     GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
889                     GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
890                   node-parameters: false
891                   kill-phase-on: FAILURE
892                   abort-all-job: true
893                   git-revision: true
894         - multijob:
895             name: deploy-virtual
896             condition: SUCCESSFUL
897             projects:
898                 - name: 'apex-deploy-virtual-{stream}'
899                   current-parameters: false
900                   predefined-parameters: |
901                     DEPLOY_SCENARIO=os-odl_l2-netvirt_gbp_fdio-noha
902                     OPNFV_CLEAN=yes
903                     GERRIT_BRANCH=$GERRIT_BRANCH
904                     GERRIT_REFSPEC=$GERRIT_REFSPEC
905                     GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
906                     GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
907                   node-parameters: true
908                   kill-phase-on: FAILURE
909                   abort-all-job: true
910                   git-revision: false
911         - multijob:
912             name: create snapshot
913             condition: SUCCESSFUL
914             projects:
915               - name: 'apex-create-snapshot'
916                 current-parameters: true
917                 node-parameters: true
918                 kill-phase-on: FAILURE
919                 abort-all-job: true
920                 git-revision: false
921         - multijob:
922             name: upload snapshot
923             condition: SUCCESSFUL
924             projects:
925               - name: 'apex-upload-snapshot'
926                 current-parameters: true
927                 node-parameters: true
928                 kill-phase-on: FAILURE
929                 abort-all-job: true
930                 git-revision: false
931
932 - job-template:
933     name: 'apex-gs-clean-{stream}'
934
935     # Job template for clean
936     #
937     # Required Variables:
938     #     stream:    branch with - in place of / (eg. stable)
939     node: '{slave}'
940
941     disabled: false
942
943     parameters:
944         - project-parameter:
945             project: '{project}'
946             branch: '{branch}'
947         - apex-parameter:
948             gs-pathname: '{gs-pathname}'
949
950     builders:
951         - 'apex-gs-clean'
952
953     triggers:
954         - 'apex-gs-clean-{stream}'
955
956 ########################
957 # parameter macros
958 ########################
959 - parameter:
960     name: apex-parameter
961     parameters:
962         - string:
963             name: ARTIFACT_NAME
964             default: 'latest'
965             description: "RPM Artifact name that will be appended to GS_URL to deploy a specific artifact"
966         - string:
967             name: ARTIFACT_VERSION
968             default: 'daily'
969             description: "Artifact version type"
970         - string:
971             name: BUILD_DIRECTORY
972             default: $WORKSPACE/.build
973             description: "Directory where the build artifact will be located upon the completion of the build."
974         - string:
975             name: CACHE_DIRECTORY
976             default: $HOME/opnfv/apex-cache{gs-pathname}
977             description: "Directory where the cache to be used during the build is located."
978         - string:
979             name: GIT_BASE
980             default: https://gerrit.opnfv.org/gerrit/$PROJECT
981             description: "Used for overriding the GIT URL coming from Global Jenkins configuration in case if the stuff is done on none-LF HW."
982         - string:
983             name: GS_PATHNAME
984             default: '{gs-pathname}'
985             description: "Version directory where opnfv artifacts are stored in gs repository"
986         - string:
987             name: GS_URL
988             default: $GS_BASE{gs-pathname}
989             description: "URL to Google Storage."
990
991 ########################
992 # builder macros
993 ########################
994 - builder:
995     name: 'apex-unit-test'
996     builders:
997         - shell:
998             !include-raw: ./apex-unit-test.sh
999
1000 - builder:
1001     name: 'apex-build'
1002     builders:
1003         - shell:
1004             !include-raw: ./apex-build.sh
1005
1006 - builder:
1007     name: 'apex-workspace-cleanup'
1008     builders:
1009         - shell:
1010             !include-raw: ./apex-workspace-cleanup.sh
1011
1012 - builder:
1013     name: 'apex-iso-verify'
1014     builders:
1015         - shell:
1016             !include-raw: ./apex-iso-verify.sh
1017
1018
1019 - builder:
1020     name: 'apex-upload-artifact'
1021     builders:
1022         - shell:
1023             !include-raw: ./apex-upload-artifact.sh
1024
1025 - builder:
1026     name: 'apex-download-artifact'
1027     builders:
1028         - shell:
1029             !include-raw: ./apex-download-artifact.sh
1030
1031 - builder:
1032     name: 'apex-gs-cleanup'
1033     builders:
1034         - shell:
1035             !include-raw: ./apex-gs-cleanup.sh
1036
1037 - builder:
1038     name: 'apex-deploy'
1039     builders:
1040         - shell:
1041             !include-raw: ./apex-deploy.sh
1042
1043 #######################
1044 # trigger macros
1045 ########################
1046 - trigger:
1047     name: 'apex-master'
1048     triggers:
1049         - timed: '0 3 1 1 7'
1050 - trigger:
1051     name: 'apex-danube'
1052     triggers:
1053         - timed: '0 12 * * *'
1054 - trigger:
1055     name: 'apex-gs-clean-{stream}'
1056     triggers:
1057         - timed: '0 2 * * *'