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