3dd091f87a35c34d22c3dde50c0a0d9e91c2f72e
[releng.git] / jjb / compass4nfv / compass-project-jobs.yml
1 - project:
2
3     name: compass-project
4
5     installer: 'compass'
6
7     project: 'compass4nfv'
8
9     stream:
10         - master:
11             branch: '{stream}'
12             gs-pathname: ''
13         - brahmaputra:
14             branch: 'stable/{stream}'
15             gs-pathname: '/{stream}'
16
17
18     jobs:
19         - 'compass-verify-{stream}'
20         - 'compass-build-iso-{stream}'
21         - 'compass-build-ppa-{stream}'
22         - 'compass-verify-deploy-{stream}'
23
24
25 ########################
26 # job templates
27 ########################
28 - job-template:
29     name: 'compass-verify-{stream}'
30
31     disabled: false
32
33     node: 'huawei-virtual'
34
35     concurrent: true
36
37     wrappers:
38         - timeout:
39             timeout: 120
40             fail: true
41
42     properties:
43         - throttle:
44             enabled: true
45             max-total: 0
46             max-per-node: 1
47
48     parameters:
49         - project-parameter:
50             project: '{project}'
51         - gerrit-parameter:
52             branch: '{branch}'
53         - compass-project-parameter:
54             installer: '{installer}'
55             gs-pathname: '{gs-pathname}'
56         - '{node}-defaults'
57         - '{installer}-defaults'
58         - string:
59             name: DEPLOY_SCENARIO
60             default: 'os-nosdn-nofeature-ha'
61
62     scm:
63         - gerrit-trigger-scm:
64             credentials-id: '{ssh-credentials}'
65             refspec: '$GERRIT_REFSPEC'
66             choosing-strategy: 'gerrit'
67
68     triggers:
69         - gerrit:
70             trigger-on:
71                 - patchset-created-event:
72                     exclude-drafts: 'false'
73                     exclude-trivial-rebase: 'false'
74                     exclude-no-code-change: 'false'
75                 - draft-published-event
76                 - comment-added-contains-event:
77                     comment-contains-value: 'recheck'
78                 - comment-added-contains-event:
79                     comment-contains-value: 'reverify'
80             projects:
81               - project-compare-type: 'ANT'
82                 project-pattern: '{project}'
83                 branches:
84                   - branch-compare-type: 'ANT'
85                     branch-pattern: '**/{branch}'
86                 forbidden-file-paths:
87                   - compare-type: ANT
88                     pattern: 'docs/**|.gitignore'
89
90     builders:
91         - trigger-builds:
92             - project: 'compass-verify-deploy-{stream}'
93               current-parameters: true
94               same-node: true
95               block: true
96
97 - job-template:
98     name: 'compass-verify-deploy-{stream}'
99
100     concurrent: true
101
102     properties:
103         - throttle:
104             enabled: true
105             max-total: 0
106             max-per-node: 1
107
108     scm:
109         - git-scm:
110             credentials-id: '{ssh-credentials}'
111             refspec: ''
112             branch: '{branch}'
113
114     builders:
115         - shell:
116             !include-raw: ./compass-build.sh
117         - shell:
118             !include-raw: ./compass-deploy.sh
119
120     publishers:
121         - archive:
122             artifacts: 'ansible.log'
123             allow-empty: 'true'
124             fingerprint: true
125
126 - job-template:
127     name: 'compass-build-iso-{stream}'
128
129     node: ericsson-build
130
131     concurrent: true
132
133     properties:
134         - throttle:
135             enabled: true
136             max-total: 1
137             max-per-node: 1
138
139     parameters:
140         - project-parameter:
141             project: '{project}'
142         - compass-project-parameter:
143             installer: '{installer}'
144             gs-pathname: '{gs-pathname}'
145         - '{node}-defaults'
146         - '{installer}-defaults'
147
148     scm:
149         - git-scm:
150             credentials-id: '{ssh-credentials}'
151             refspec: ''
152             branch: '{branch}'
153
154     triggers:
155         - timed: 'H 14 * * *'
156
157     builders:
158         - shell:
159             !include-raw: ./compass-build.sh
160         - shell:
161             !include-raw: ./compass-upload-artifact.sh
162         - shell:
163             !include-raw: ./compass-workspace-cleanup.sh
164
165 - job-template:
166     name: 'compass-build-ppa-{stream}'
167
168     description: "build ppa(using docker) in huawei lab"
169
170     node: huawei-build
171
172     concurrent: true
173
174     properties:
175         - throttle:
176             enabled: true
177             max-total: 1
178             max-per-node: 1
179
180     parameters:
181         - project-parameter:
182             project: '{project}'
183         - compass-project-parameter:
184             installer: '{installer}'
185             gs-pathname: '{gs-pathname}'
186         - '{node}-defaults'
187         - '{installer}-defaults'
188     scm:
189         - git-scm:
190             credentials-id: '{ssh-credentials}'
191             refspec: ''
192             branch: '{branch}'
193
194     builders:
195         - shell:
196             !include-raw: ./compass-makeppa.sh
197
198
199
200 ########################
201 # parameter macros
202 ########################
203 - parameter:
204     name: compass-project-parameter
205     parameters:
206         - string:
207             name: BUILD_DIRECTORY
208             default: $WORKSPACE/build_output
209             description: "Directory where the build artifact will be located upon the completion of the build."
210         - string:
211             name: CACHE_DIRECTORY
212             default: "$HOME/opnfv/cache/$PROJECT{gs-pathname}"
213             description: "Directory where the cache to be used during the build is located."
214         - string:
215             name: GS_URL
216             default: '$GS_BASE{gs-pathname}'
217             description: "URL to Google Storage."
218         - string:
219             name: PPA_REPO
220             default: "http://205.177.226.237:9999{gs-pathname}"
221         - string:
222             name: PPA_CACHE
223             default: "$WORKSPACE/work/repo/"
224         - choice:
225             name: COMPASS_OPENSTACK_VERSION
226             choices:
227                 - 'liberty'
228                 - 'juno'
229         - choice:
230             name: COMPASS_OS_VERSION
231             choices:
232                 - 'trusty'
233                 - 'centos7'
234