Apex: updates cache to unique name
[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                 - 'apex-verify.*'
156         - throttle:
157             max-per-node: 1
158             max-total: 10
159             option: 'project'
160
161     builders:
162         - description-setter:
163             description: "Built on $NODE_NAME"
164         - multijob:
165             name: basic
166             condition: SUCCESSFUL
167             projects:
168                 - name: 'apex-verify-unit-tests-{stream}'
169                   current-parameters: false
170                   predefined-parameters: |
171                     GERRIT_BRANCH=$GERRIT_BRANCH
172                     GERRIT_REFSPEC=$GERRIT_REFSPEC
173                     GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
174                     GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
175                   node-parameters: false
176                   kill-phase-on: FAILURE
177                   abort-all-job: true
178                   git-revision: true
179         - multijob:
180             name: build
181             condition: SUCCESSFUL
182             projects:
183                 - name: 'apex-build-{stream}'
184                   current-parameters: false
185                   predefined-parameters: |
186                     ARTIFACT_VERSION=$ARTIFACT_VERSION
187                     GERRIT_BRANCH=$GERRIT_BRANCH
188                     GERRIT_REFSPEC=$GERRIT_REFSPEC
189                     GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
190                     GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
191                   node-parameters: false
192                   kill-phase-on: FAILURE
193                   abort-all-job: true
194                   git-revision: true
195         - multijob:
196             name: deploy-virtual
197             condition: SUCCESSFUL
198             projects:
199                 - name: 'apex-deploy-virtual-{stream}'
200                   current-parameters: false
201                   predefined-parameters: |
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: false
209                   kill-phase-on: FAILURE
210                   abort-all-job: true
211                   git-revision: false
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: false
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
251     scm:
252         - git-scm-gerrit
253
254     triggers:
255         - gerrit:
256             server-name: 'gerrit.opnfv.org'
257             trigger-on:
258                 - comment-added-contains-event:
259                     comment-contains-value: '^Patch Set [0-9]+: Code-Review\+2.*start-gate-scenario:.*'
260             projects:
261               - project-compare-type: 'ANT'
262                 project-pattern: 'apex'
263                 branches:
264                   - branch-compare-type: 'ANT'
265                     branch-pattern: '**/{branch}'
266                 file-paths:
267                   - compare-type: ANT
268                     pattern: 'ci/**'
269                   - compare-type: ANT
270                     pattern: 'build/**'
271                   - compare-type: ANT
272                     pattern: 'lib/**'
273                   - compare-type: ANT
274                     pattern: 'config/**'
275
276     properties:
277         - logrotate-default
278         - build-blocker:
279             use-build-blocker: true
280             block-level: 'NODE'
281             blocking-jobs:
282                 - 'apex-daily.*'
283                 - 'apex-deploy.*'
284                 - 'apex-build.*'
285                 - 'apex-runner.*'
286                 - 'apex-verify.*'
287         - throttle:
288             max-per-node: 1
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                     DEPLOY_SCENARIO=gate
301                     OPNFV_CLEAN=yes
302                     GERRIT_BRANCH=$GERRIT_BRANCH
303                     GERRIT_REFSPEC=$GERRIT_REFSPEC
304                     GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
305                     GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
306                   node-parameters: false
307                   kill-phase-on: FAILURE
308                   abort-all-job: true
309                   git-revision: false
310         - multijob:
311             name: functest-smoke
312             condition: SUCCESSFUL
313             projects:
314               - name: 'functest-apex-virtual-suite-{stream}'
315                 current-parameters: false
316                 predefined-parameters: |
317                   DEPLOY_SCENARIO={verify-scenario}
318                   FUNCTEST_SUITE_NAME=healthcheck
319                   GERRIT_BRANCH=$GERRIT_BRANCH
320                   GERRIT_REFSPEC=$GERRIT_REFSPEC
321                   GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
322                   GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
323                 node-parameters: false
324                 kill-phase-on: FAILURE
325                 abort-all-job: true
326                 git-revision: false
327
328 - job-template:
329     name: 'apex-runner-cperf-{stream}'
330
331     # runner cperf job
332     project-type: 'multijob'
333     node: 'intel-pod2'
334
335     disabled: false
336
337     parameters:
338         - apex-parameter:
339             gs-pathname: '{gs-pathname}'
340         - project-parameter:
341             project: '{project}'
342             branch: '{branch}'
343         - string:
344             name: GIT_BASE
345             default: https://gerrit.opnfv.org/gerrit/$PROJECT
346             description: "Used for overriding the GIT URL coming from parameters macro."
347
348     scm:
349         - git-scm
350
351     properties:
352         - logrotate-default
353         - build-blocker:
354             use-build-blocker: false
355             block-level: 'NODE'
356             blocking-jobs:
357                 - 'apex-deploy.*'
358         - throttle:
359             max-per-node: 1
360             max-total: 10
361             option: 'project'
362
363     builders:
364         - description-setter:
365             description: "Deployed on $NODE_NAME"
366         - multijob:
367             name: 'Baremetal Deploy'
368             condition: ALWAYS
369             projects:
370                 - name: 'apex-deploy-baremetal-{stream}'
371                   node-parameters: false
372                   current-parameters: true
373                   predefined-parameters: |
374                     OPNFV_CLEAN=yes
375                     DEPLOY_SCENARIO={verify-scenario}
376                   kill-phase-on: FAILURE
377                   abort-all-job: true
378                   git-revision: false
379         - multijob:
380             name: Functest
381             condition: ALWAYS
382             projects:
383                 - name: 'functest-apex-baremetal-daily-{stream}'
384                   node-parameters: true
385                   current-parameters: false
386                   predefined-parameters:
387                     DEPLOY_SCENARIO={verify-scenario}
388                   kill-phase-on: NEVER
389                   abort-all-job: false
390                   git-revision: false
391
392 # Build phase
393 - job-template:
394     name: 'apex-build-{stream}'
395
396     # Job template for builds
397     #
398     # Required Variables:
399     #     stream:    branch with - in place of / (eg. stable)
400     #     branch:    branch (eg. stable)
401     node: '{build-slave}'
402
403     disabled: false
404
405     concurrent: true
406
407     parameters:
408         - '{project}-defaults'
409         - project-parameter:
410             project: '{project}'
411             branch: '{branch}'
412         - apex-parameter:
413             gs-pathname: '{gs-pathname}'
414
415     scm:
416         - git-scm-gerrit
417
418     wrappers:
419         - timeout:
420             timeout: 90
421             fail: true
422
423     properties:
424         - logrotate-default
425         - throttle:
426             max-per-node: 1
427             max-total: 10
428             option: 'project'
429
430     builders:
431         - 'apex-build'
432         - inject:
433            properties-content: ARTIFACT_TYPE=rpm
434         - 'apex-upload-artifact'
435
436 # ISO verify job
437 - job-template:
438     name: 'apex-verify-iso-{stream}'
439
440     # Job template for builds
441     #
442     # Required Variables:
443     #     stream:    branch with - in place of / (eg. stable)
444     #     branch:    branch (eg. stable)
445     node: '{virtual-slave}'
446
447     disabled: false
448
449     concurrent: true
450
451     parameters:
452         - project-parameter:
453             project: '{project}'
454             branch: '{branch}'
455         - apex-parameter:
456             gs-pathname: '{gs-pathname}'
457         - string:
458             name: GIT_BASE
459             default: https://gerrit.opnfv.org/gerrit/$PROJECT
460             description: "Used for overriding the GIT URL coming from parameters macro."
461
462     scm:
463         - git-scm
464
465     properties:
466         - logrotate-default
467         - build-blocker:
468             use-build-blocker: true
469             block-level: 'NODE'
470             blocking-jobs:
471                 - 'apex-deploy.*'
472         - throttle:
473             max-per-node: 1
474             max-total: 10
475             option: 'project'
476
477     builders:
478         - 'apex-iso-verify'
479         - inject:
480            properties-content: ARTIFACT_TYPE=iso
481         - 'apex-upload-artifact'
482
483 # Deploy job
484 - job-template:
485     name: 'apex-deploy-{platform}-{stream}'
486
487     # Job template for virtual deployment
488     #
489     # Required Variables:
490     #     stream:    branch with - in place of / (eg. stable)
491     #     branch:    branch (eg. stable)
492     node: 'apex-{platform}-{stream}'
493
494     concurrent: true
495
496     disabled: false
497
498     scm:
499         - git-scm
500
501     wrappers:
502         - timeout:
503             timeout: 120
504             fail: true
505
506     parameters:
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         - throttle:
529             max-per-node: 1
530             max-total: 10
531             option: 'project'
532
533     builders:
534         - description-setter:
535             description: "Deployed on $NODE_NAME - Scenario: $DEPLOY_SCENARIO"
536         - 'apex-download-artifact'
537         - 'apex-deploy'
538         - 'apex-workspace-cleanup'
539
540
541 # Baremetal Deploy and Test
542 - job-template:
543     name: 'apex-deploy-test-baremetal-{stream}'
544
545     # Job template for daily build
546     #
547     # Required Variables:
548     #     stream:    branch with - in place of / (eg. stable)
549     #     branch:    branch (eg. stable)
550     project-type: 'multijob'
551
552     disabled: false
553
554     scm:
555         - git-scm
556
557     parameters:
558         - '{project}-defaults'
559         - '{project}-baremetal-{stream}-defaults'
560         - project-parameter:
561             project: '{project}'
562             branch: '{branch}'
563         - apex-parameter:
564             gs-pathname: '{gs-pathname}'
565         - string:
566             name: DEPLOY_SCENARIO
567             default: '{verify-scenario}'
568             description: "Scenario to deploy with."
569     properties:
570         - logrotate-default
571         - build-blocker:
572             use-build-blocker: true
573             block-level: 'NODE'
574             blocking-jobs:
575                 - 'apex-verify.*'
576                 - 'apex-deploy.*'
577                 - 'apex-runner.*'
578                 - 'apex-.*-promote.*'
579     builders:
580         - description-setter:
581             description: "Deployed on $NODE_NAME - Scenario: $DEPLOY_SCENARIO"
582         - multijob:
583             name: 'Baremetal Deploy'
584             condition: ALWAYS
585             projects:
586                 - name: 'apex-deploy-baremetal-{stream}'
587                   node-parameters: true
588                   current-parameters: true
589                   predefined-parameters: |
590                     OPNFV_CLEAN=yes
591                   kill-phase-on: FAILURE
592                   abort-all-job: true
593                   git-revision: false
594         - multijob:
595             name: Functest
596             condition: ALWAYS
597             projects:
598                 - name: 'functest-apex-baremetal-daily-{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-{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=$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=apex-build-{{ stream }}/.build
677                     GERRIT_BRANCH=$GERRIT_BRANCH
678                     GERRIT_REFSPEC=$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-deploy-test-baremetal-{{ stream }}'
691                   node-parameters: false
692                   current-parameters: false
693                   predefined-parameters: |
694                     DEPLOY_SCENARIO={{scenario}}
695                     OPNFV_CLEAN=yes
696                   kill-phase-on: NEVER
697                   abort-all-job: true
698                   git-revision: false
699 {% endfor %}
700 {% endfor %}
701
702 # snapshot create
703 - job-template:
704     name: 'apex-create-snapshot'
705
706     # Job template for clean
707     #
708     # Required Variables:
709     #     stream:    branch with - in place of / (eg. stable)
710
711     disabled: false
712
713     builders:
714         - shell:
715             !include-raw-escape: ./apex-snapshot-create.sh
716
717 # snapshot upload
718 - job-template:
719     name: 'apex-upload-snapshot'
720
721     # Job template for clean
722     #
723     # Required Variables:
724     #     stream:    branch with - in place of / (eg. stable)
725
726     disabled: false
727
728     builders:
729         - inject:
730            properties-content: ARTIFACT_TYPE=snapshot
731         - 'apex-upload-artifact'
732
733 # CSIT promote
734 - job-template:
735     name: 'apex-csit-promote-daily-{stream}'
736
737     # Job template for promoting CSIT Snapshots
738     #
739     # Required Variables:
740     #     stream:    branch with - in place of / (eg. stable)
741     #     branch:    branch (eg. stable)
742     node: '{virtual-slave}'
743     project-type: 'multijob'
744     disabled: false
745
746     scm:
747         - git-scm
748
749     parameters:
750         - project-parameter:
751             project: '{project}'
752             branch: '{branch}'
753         - apex-parameter:
754             gs-pathname: '{gs-pathname}'
755
756     properties:
757         - build-blocker:
758             use-build-blocker: true
759             block-level: 'NODE'
760             blocking-jobs:
761                 - 'apex-verify.*'
762                 - 'apex-deploy.*'
763                 - 'apex-build.*'
764                 - 'apex-runner.*'
765                 - 'apex-daily.*'
766
767     triggers:
768         - timed: '0 12 * * 0'
769
770     builders:
771         - multijob:
772             name: build
773             condition: SUCCESSFUL
774             projects:
775                 - name: 'apex-build-{stream}'
776                   current-parameters: false
777                   predefined-parameters: |
778                     GERRIT_BRANCH=$GERRIT_BRANCH
779                     GERRIT_REFSPEC=$GERRIT_REFSPEC
780                     GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
781                     GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
782                   node-parameters: false
783                   kill-phase-on: FAILURE
784                   abort-all-job: true
785                   git-revision: true
786         - multijob:
787             name: deploy-virtual
788             condition: SUCCESSFUL
789             projects:
790                 - name: 'apex-deploy-virtual-{stream}'
791                   current-parameters: false
792                   predefined-parameters: |
793                     DEPLOY_SCENARIO=os-odl_l3-csit-noha
794                     OPNFV_CLEAN=yes
795                     GERRIT_BRANCH=$GERRIT_BRANCH
796                     GERRIT_REFSPEC=$GERRIT_REFSPEC
797                     GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
798                     GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
799                   node-parameters: true
800                   kill-phase-on: FAILURE
801                   abort-all-job: true
802                   git-revision: false
803         - multijob:
804             name: functest-smoke
805             condition: SUCCESSFUL
806             projects:
807               - name: 'functest-apex-virtual-suite-{stream}'
808                 current-parameters: false
809                 predefined-parameters: |
810                   DEPLOY_SCENARIO=os-odl_l3-nofeature-noha
811                   FUNCTEST_SUITE_NAME=tempest_smoke_serial
812                   GERRIT_BRANCH=$GERRIT_BRANCH
813                   GERRIT_REFSPEC=$GERRIT_REFSPEC
814                   GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
815                   GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
816                 node-parameters: true
817                 kill-phase-on: FAILURE
818                 abort-all-job: true
819                 git-revision: false
820         - multijob:
821             name: create snapshot
822             condition: SUCCESSFUL
823             projects:
824               - name: 'apex-create-snapshot'
825                 current-parameters: true
826                 node-parameters: true
827                 kill-phase-on: FAILURE
828                 abort-all-job: true
829                 git-revision: false
830         - multijob:
831             name: upload snapshot
832             condition: SUCCESSFUL
833             projects:
834               - name: 'apex-upload-snapshot'
835                 current-parameters: true
836                 node-parameters: true
837                 kill-phase-on: FAILURE
838                 abort-all-job: true
839                 git-revision: false
840
841 # FDIO promote
842 - job-template:
843     name: 'apex-fdio-promote-daily-{stream}'
844
845     # Job template for promoting CSIT Snapshots
846     #
847     # Required Variables:
848     #     stream:    branch with - in place of / (eg. stable)
849     #     branch:    branch (eg. stable)
850     node: '{virtual-slave}'
851     project-type: 'multijob'
852     disabled: false
853
854     scm:
855         - git-scm
856
857     parameters:
858         - project-parameter:
859             project: '{project}'
860             branch: '{branch}'
861         - apex-parameter:
862             gs-pathname: '{gs-pathname}'
863
864     properties:
865         - build-blocker:
866             use-build-blocker: true
867             block-level: 'NODE'
868             blocking-jobs:
869                 - 'apex-verify.*'
870                 - 'apex-deploy.*'
871                 - 'apex-build.*'
872                 - 'apex-runner.*'
873                 - 'apex-daily.*'
874
875     builders:
876         - multijob:
877             name: build
878             condition: SUCCESSFUL
879             projects:
880                 - name: 'apex-build-{stream}'
881                   current-parameters: false
882                   predefined-parameters: |
883                     GERRIT_BRANCH=$GERRIT_BRANCH
884                     GERRIT_REFSPEC=$GERRIT_REFSPEC
885                     GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
886                     GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
887                   node-parameters: false
888                   kill-phase-on: FAILURE
889                   abort-all-job: true
890                   git-revision: true
891         - multijob:
892             name: deploy-virtual
893             condition: SUCCESSFUL
894             projects:
895                 - name: 'apex-deploy-virtual-{stream}'
896                   current-parameters: false
897                   predefined-parameters: |
898                     DEPLOY_SCENARIO=os-odl_l2-netvirt_gbp_fdio-noha
899                     OPNFV_CLEAN=yes
900                     GERRIT_BRANCH=$GERRIT_BRANCH
901                     GERRIT_REFSPEC=$GERRIT_REFSPEC
902                     GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
903                     GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
904                   node-parameters: true
905                   kill-phase-on: FAILURE
906                   abort-all-job: true
907                   git-revision: false
908         - multijob:
909             name: create snapshot
910             condition: SUCCESSFUL
911             projects:
912               - name: 'apex-create-snapshot'
913                 current-parameters: true
914                 node-parameters: true
915                 kill-phase-on: FAILURE
916                 abort-all-job: true
917                 git-revision: false
918         - multijob:
919             name: upload snapshot
920             condition: SUCCESSFUL
921             projects:
922               - name: 'apex-upload-snapshot'
923                 current-parameters: true
924                 node-parameters: true
925                 kill-phase-on: FAILURE
926                 abort-all-job: true
927                 git-revision: false
928
929 - job-template:
930     name: 'apex-gs-clean-{stream}'
931
932     # Job template for clean
933     #
934     # Required Variables:
935     #     stream:    branch with - in place of / (eg. stable)
936     node: '{slave}'
937
938     disabled: false
939
940     parameters:
941         - project-parameter:
942             project: '{project}'
943             branch: '{branch}'
944         - apex-parameter:
945             gs-pathname: '{gs-pathname}'
946
947     builders:
948         - 'apex-gs-clean'
949
950     triggers:
951         - 'apex-gs-clean-{stream}'
952
953 ########################
954 # parameter macros
955 ########################
956 - parameter:
957     name: apex-parameter
958     parameters:
959         - string:
960             name: ARTIFACT_NAME
961             default: 'latest'
962             description: "RPM Artifact name that will be appended to GS_URL to deploy a specific artifact"
963         - string:
964             name: ARTIFACT_VERSION
965             default: 'daily'
966             description: "Artifact version type"
967         - string:
968             name: BUILD_DIRECTORY
969             default: $WORKSPACE/.build
970             description: "Directory where the build artifact will be located upon the completion of the build."
971         - string:
972             name: CACHE_DIRECTORY
973             default: $HOME/opnfv/apex-cache{gs-pathname}
974             description: "Directory where the cache to be used during the build is located."
975         - string:
976             name: GIT_BASE
977             default: https://gerrit.opnfv.org/gerrit/$PROJECT
978             description: "Used for overriding the GIT URL coming from Global Jenkins configuration in case if the stuff is done on none-LF HW."
979         - string:
980             name: GS_PATHNAME
981             default: '{gs-pathname}'
982             description: "Version directory where opnfv artifacts are stored in gs repository"
983         - string:
984             name: GS_URL
985             default: $GS_BASE{gs-pathname}
986             description: "URL to Google Storage."
987
988 ########################
989 # builder macros
990 ########################
991 - builder:
992     name: 'apex-unit-test'
993     builders:
994         - shell:
995             !include-raw: ./apex-unit-test.sh
996
997 - builder:
998     name: 'apex-build'
999     builders:
1000         - shell:
1001             !include-raw: ./apex-build.sh
1002
1003 - builder:
1004     name: 'apex-workspace-cleanup'
1005     builders:
1006         - shell:
1007             !include-raw: ./apex-workspace-cleanup.sh
1008
1009 - builder:
1010     name: 'apex-iso-verify'
1011     builders:
1012         - shell:
1013             !include-raw: ./apex-iso-verify.sh
1014
1015
1016 - builder:
1017     name: 'apex-upload-artifact'
1018     builders:
1019         - shell:
1020             !include-raw: ./apex-upload-artifact.sh
1021
1022 - builder:
1023     name: 'apex-download-artifact'
1024     builders:
1025         - shell:
1026             !include-raw: ./apex-download-artifact.sh
1027
1028 - builder:
1029     name: 'apex-gs-cleanup'
1030     builders:
1031         - shell:
1032             !include-raw: ./apex-gs-cleanup.sh
1033
1034 - builder:
1035     name: 'apex-deploy'
1036     builders:
1037         - shell:
1038             !include-raw: ./apex-deploy.sh
1039
1040 #######################
1041 # trigger macros
1042 ########################
1043 - trigger:
1044     name: 'apex-master'
1045     triggers:
1046         - timed: '0 3 1 1 7'
1047 - trigger:
1048     name: 'apex-danube'
1049     triggers:
1050         - timed: '0 12 * * *'
1051 - trigger:
1052     name: 'apex-gs-clean-{stream}'
1053     triggers:
1054         - timed: '0 2 * * *'