update blocked jobs
[releng.git] / jjb / daisy4nfv / daisy4nfv-verify-jobs.yml
1 - project:
2     name: 'daisy4nfv-verify-jobs'
3     project: 'daisy'
4     installer: 'daisy'
5 ##########################################################
6 # use alias to keep the jobs'name existed alread unchanged
7 ##########################################################
8     alias: 'daisy4nfv'
9
10 #####################################
11 # branch definitions
12 #####################################
13     stream:
14         - master:
15             branch: '{stream}'
16             gs-pathname: ''
17             disabled: false
18         - danube:
19             branch: 'stable/{stream}'
20             gs-pathname: '/{stream}'
21             disabled: false
22 #####################################
23 # patch verification phases
24 #####################################
25     phase:
26         - unit:
27             slave-label: 'opnfv-build'
28         - build:
29             slave-label: 'opnfv-build-centos'
30 #####################################
31 # jobs
32 #####################################
33     jobs:
34         - '{alias}-verify-{stream}'
35         - '{alias}-verify-{phase}-{stream}'
36 #####################################
37 # job templates
38 #####################################
39 - job-template:
40     name: '{alias}-verify-{stream}'
41     project-type: multijob
42     disabled: false
43     concurrent: true
44     properties:
45         - logrotate-default
46         - throttle:
47             enabled: true
48             max-total: 4
49             option: 'project'
50         - build-blocker:
51             use-build-blocker: true
52             blocking-jobs:
53                 - '{installer}-merge-build-.*'
54             block-level: 'NODE'
55
56     scm:
57         - git-scm
58     wrappers:
59         - ssh-agent-wrapper
60         - timeout:
61             timeout: 360
62             fail: true
63     triggers:
64         - gerrit:
65             server-name: 'gerrit.opnfv.org'
66             trigger-on:
67                 - patchset-created-event:
68                     exclude-drafts: 'false'
69                     exclude-trivial-rebase: 'false'
70                     exclude-no-code-change: 'false'
71                 - draft-published-event
72                 - comment-added-contains-event:
73                     comment-contains-value: 'recheck'
74                 - comment-added-contains-event:
75                     comment-contains-value: 'reverify'
76             projects:
77                 - project-compare-type: 'ANT'
78                   project-pattern: '{project}'
79                   branches:
80                       - branch-compare-type: 'ANT'
81                         branch-pattern: '**/{branch}'
82                   file-paths:
83                       - compare-type: ANT
84                         pattern: 'ci/**'
85                       - compare-type: ANT
86                         pattern: 'code/**'
87                       - compare-type: ANT
88                         pattern: 'deploy/**'
89                   disable-strict-forbidden-file-verification: 'true'
90                   forbidden-file-paths:
91                       - compare-type: ANT
92                         pattern: 'docs/**'
93                       - compare-type: ANT
94                         pattern: '.gitignore'
95             readable-message: true
96
97     parameters:
98         - project-parameter:
99             project: '{project}'
100             branch: '{branch}'
101         - 'opnfv-build-centos-defaults'
102         - '{alias}-verify-defaults':
103             gs-pathname: '{gs-pathname}'
104
105     builders:
106         - description-setter:
107             description: "Built on $NODE_NAME"
108         - multijob:
109             name: unit
110             condition: SUCCESSFUL
111             projects:
112                 - name: '{alias}-verify-{name}-{stream}'
113                   current-parameters: true
114                   node-parameters: false
115                   kill-phase-on: FAILURE
116                   abort-all-job: true
117         - multijob:
118             name: build
119             condition: SUCCESSFUL
120             projects:
121                 - name: '{alias}-verify-build-{stream}'
122                   current-parameters: false
123                   predefined-parameters: |
124                     BRANCH=$BRANCH
125                     GERRIT_REFSPEC=$GERRIT_REFSPEC
126                     GERRIT_CHANGE_NUMBER=$GERRIT_CHANGE_NUMBER
127                     GERRIT_CHANGE_COMMIT_MESSAGE=$GERRIT_CHANGE_COMMIT_MESSAGE
128                   node-parameters: false
129                   kill-phase-on: FAILURE
130                   abort-all-job: true
131
132 - job-template:
133     name: '{alias}-verify-{phase}-{stream}'
134     disabled: '{obj:disabled}'
135     concurrent: true
136     properties:
137         - logrotate-default
138         - throttle:
139             enabled: true
140             max-total: 6
141             option: 'project'
142         - build-blocker:
143             use-build-blocker: true
144             blocking-jobs:
145                 - '{installer}-merge-build-.*'
146                 - '{alias}-verify-build-.*'
147             block-level: 'NODE'
148
149     scm:
150         - git-scm
151     wrappers:
152         - ssh-agent-wrapper
153         - timeout:
154             timeout: 360
155             fail: true
156     parameters:
157         - project-parameter:
158             project: '{project}'
159             branch: '{branch}'
160         - '{slave-label}-defaults'
161         - '{alias}-verify-defaults':
162             gs-pathname: '{gs-pathname}'
163
164     builders:
165         - description-setter:
166             description: "Built on $NODE_NAME"
167         - '{project}-verify-{phase}-macro'
168
169 #####################################
170 # builder macros
171 #####################################
172 - builder:
173     name: 'daisy-verify-build-macro'
174     builders:
175         - shell:
176             !include-raw: ./daisy4nfv-basic.sh
177         - shell:
178             !include-raw: ./daisy4nfv-build.sh
179         - shell:
180             !include-raw: ./daisy4nfv-workspace-cleanup.sh
181
182 - builder:
183     name: daisy-verify-unit-macro
184     builders:
185         - shell: |
186             #!/bin/bash
187             set -o errexit
188             set -o pipefail
189             set -o xtrace
190             tox -e py27
191
192 #####################################
193 # parameter macros
194 #####################################
195 - parameter:
196     name: 'daisy4nfv-verify-defaults'
197     parameters:
198         - string:
199             name: BUILD_DIRECTORY
200             default: $WORKSPACE/build_output
201             description: "Directory where the build artifact will be located upon the completion of the build."
202         - string:
203             name: CACHE_DIRECTORY
204             default: $HOME/opnfv/cache/$INSTALLER_TYPE
205             description: "Directory where the cache to be used during the build is located."
206         - string:
207             name: GS_URL
208             default: artifacts.opnfv.org/$PROJECT{gs-pathname}
209             description: "URL to Google Storage."