6ef5fbb670d93755d4ad75a505cd4ca0282e1aa8
[releng.git] / jjb / compass4nfv / compass-verify-jobs.yml
1 - project:
2     name: 'compass-verify-jobs'
3
4     project: 'compass4nfv'
5
6     installer: 'compass'
7 #####################################
8 # branch definitions
9 #####################################
10     stream:
11         - master:
12             branch: '{stream}'
13             gs-pathname: ''
14             disabled: false
15         - danube:
16             branch: 'stable/{stream}'
17             gs-pathname: '/{stream}'
18             disabled: false
19
20     distro:
21         - 'xenial':
22             disabled: false
23             os-version: 'xenial'
24             openstack-os-version: ''
25 #####################################
26 # patch verification phases
27 #####################################
28     phase:
29         - 'basic'
30         - 'deploy-virtual'
31 #####################################
32 # jobs
33 #####################################
34     jobs:
35         - 'compass-verify-{distro}-{stream}'
36         - 'compass-verify-{phase}-{distro}-{stream}'
37 #####################################
38 # job templates
39 #####################################
40 - job-template:
41     name: 'compass-verify-{distro}-{stream}'
42
43     project-type: multijob
44
45     disabled: '{obj:disabled}'
46
47     concurrent: true
48
49     properties:
50         - throttle:
51             enabled: true
52             max-total: 4
53             max-per-node: 1
54             option: 'project'
55         - build-blocker:
56             use-build-blocker: true
57             blocking-jobs:
58                 - 'compass-verify-[^-]*-[^-]*'
59                 - 'compass-os-.*?-virtual-daily-.*?'
60             block-level: 'NODE'
61
62     scm:
63         - git-scm-gerrit
64
65     wrappers:
66         - ssh-agent-wrapper
67         - timeout:
68             timeout: 120
69             fail: true
70
71     triggers:
72         - gerrit:
73             server-name: 'gerrit.opnfv.org'
74             trigger-on:
75                 - patchset-created-event:
76                     exclude-drafts: 'false'
77                     exclude-trivial-rebase: 'false'
78                     exclude-no-code-change: 'false'
79                 - draft-published-event
80                 - comment-added-contains-event:
81                     comment-contains-value: 'recheck'
82                 - comment-added-contains-event:
83                     comment-contains-value: 'reverify'
84             projects:
85               - project-compare-type: 'ANT'
86                 project-pattern: '{project}'
87                 branches:
88                   - branch-compare-type: 'ANT'
89                     branch-pattern: '**/{branch}'
90                 file-paths:
91                   - compare-type: ANT
92                     pattern: '**/*'
93                 forbidden-file-paths:
94                   - compare-type: ANT
95                     pattern: 'docs/**'
96             readable-message: true
97
98     parameters:
99         - project-parameter:
100             project: '{project}'
101         - gerrit-parameter:
102             branch: '{branch}'
103         - 'compass-virtual-defaults'
104         - '{installer}-defaults'
105         - 'compass-verify-defaults':
106             installer: '{installer}'
107             gs-pathname: '{gs-pathname}'
108         - string:
109             name: DEPLOY_SCENARIO
110             default: 'os-nosdn-nofeature-ha'
111
112     builders:
113         - description-setter:
114             description: "Built on $NODE_NAME"
115         - multijob:
116             name: basic
117             condition: SUCCESSFUL
118             projects:
119                 - name: 'opnfv-lint-verify-{stream}'
120                   current-parameters: true
121                   node-parameters: true
122                   kill-phase-on: FAILURE
123                   abort-all-job: true
124         - multijob:
125             name: deploy-virtual
126             condition: SUCCESSFUL
127             projects:
128                 - name: 'compass-verify-deploy-virtual-{distro}-{stream}'
129                   current-parameters: true
130                   predefined-parameters: |
131                     COMPASS_OS_VERSION={os-version}
132                   node-parameters: true
133                   kill-phase-on: FAILURE
134                   abort-all-job: true
135         - multijob:
136             name: smoke-test
137             condition: SUCCESSFUL
138             projects:
139                 - name: 'functest-compass-virtual-suite-{stream}'
140                   current-parameters: true
141                   predefined-parameters:
142                     FUNCTEST_SUITE_NAME=healthcheck
143                   node-parameters: true
144                   kill-phase-on: NEVER
145                   abort-all-job: true
146                 - name: 'functest-compass-virtual-suite-{stream}'
147                   current-parameters: true
148                   predefined-parameters:
149                     FUNCTEST_SUITE_NAME=vping_ssh
150                   node-parameters: true
151                   kill-phase-on: NEVER
152                   abort-all-job: true
153
154 - job-template:
155     name: 'compass-verify-{phase}-{distro}-{stream}'
156
157     disabled: '{obj:disabled}'
158
159     concurrent: true
160
161     properties:
162         - throttle:
163             enabled: true
164             max-per-node: 1
165             option: 'project'
166         - build-blocker:
167             use-build-blocker: true
168             blocking-jobs:
169                 - 'compass-os-.*?-virtual-daily-.*?'
170                 - 'compass-verify-deploy-.*'
171                 - 'functest-compass-virtual.*'
172             block-level: 'NODE'
173
174     scm:
175         - git-scm-gerrit
176
177     wrappers:
178         - ssh-agent-wrapper
179         - timeout:
180             timeout: 120
181             fail: true
182
183     builders:
184         - description-setter:
185             description: "Built on $NODE_NAME"
186         - '{project}-verify-{phase}-macro'
187
188     publishers:
189         - archive:
190             artifacts: 'ansible.log'
191             allow-empty: 'true'
192             fingerprint: true
193 #####################################
194 # builder macros
195 #####################################
196 - builder:
197     name: 'compass4nfv-verify-basic-macro'
198     builders:
199         - shell: |
200             #!/bin/bash
201
202             echo "Not activated!"
203
204 - builder:
205     name: 'compass4nfv-verify-deploy-virtual-macro'
206     builders:
207         - shell:
208             !include-raw: ./compass-build.sh
209         - shell:
210             !include-raw: ./compass-deploy.sh
211 #####################################
212 # parameter macros
213 #####################################
214 - parameter:
215     name: 'compass-verify-defaults'
216     parameters:
217         - string:
218             name: BUILD_DIRECTORY
219             default: $WORKSPACE/build_output
220             description: "Directory where the build artifact will be located upon the completion of the build."
221         - string:
222             name: CACHE_DIRECTORY
223             default: "$HOME/opnfv/cache/$PROJECT{gs-pathname}"
224             description: "Directory where the cache to be used during the build is located."
225         - string:
226             name: GS_URL
227             default: '$GS_BASE{gs-pathname}'
228             description: "URL to Google Storage."
229         - string:
230             name: PPA_REPO
231             default: "http://205.177.226.237:9999{gs-pathname}"
232         - string:
233             name: PPA_CACHE
234             default: "$WORKSPACE/work/repo/"
235         - choice:
236             name: COMPASS_OPENSTACK_VERSION
237             choices:
238                 - 'newton'
239         - choice:
240             name: COMPASS_OS_VERSION
241             choices:
242                 - 'xenial'