Change the project name for genesis
[releng.git] / jjb / genesis / genesis.yml
1 # this is the job configuration for bgs
2 - project:
3
4     name: genesis
5
6     installer:
7         - foreman
8         - fuel
9         - opensteak
10     jobs:
11         - 'genesis-{installer}-verify'
12         - 'genesis-{installer}-merge'
13         - 'genesis-{installer}-daily-master'
14
15     # stream:    branch with - in place of / (eg. stable-helium)
16     # branch:    branch (eg. stable/helium)
17     stream:
18         - master:
19             branch: 'master'
20
21     project: 'genesis'
22
23 ########################
24 # job templates
25 ########################
26
27 - job-template:
28     name: 'genesis-{installer}-verify'
29
30     project-type: freestyle
31
32     node: ericsson-build
33
34     logrotate:
35         daysToKeep: 30
36         numToKeep: 10
37         artifactDaysToKeep: -1
38         artifactNumToKeep: -1
39
40     parameters:
41         - string:
42             name: BUILD_DIRECTORY
43             default: $WORKSPACE/build_output
44         - string:
45             name: GIT_BASE
46             default: https://gerrit.opnfv.org/gerrit/genesis
47         - project-parameter:
48             project: '{project}'
49         - gerrit-parameter:
50             branch: 'master'
51
52     scm:
53         - gerrit-trigger-scm:
54             credentials-id: '{ssh-credentials}'
55             refspec: '$GERRIT_REFSPEC'
56             choosing-strategy: 'gerrit'
57
58     wrappers:
59         - ssh-agent-credentials:
60             user: '{ssh-credentials}'
61
62     triggers:
63         - gerrit:
64             trigger-on:
65                 - patchset-created-event:
66                     exclude-drafts: 'false'
67                     exclude-trivial-rebase: 'false'
68                     exclude-no-code-change: 'false'
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: 'genesis'
77                 branches:
78                   - branch-compare-type: 'ANT'
79                     branch-pattern: '**/master'
80                 file-paths:
81                   - compare-type: ANT
82                     pattern: 'common/**'
83                   - compare-type: ANT
84                     pattern: '{installer}/**'
85
86
87     builders:
88         - '{installer}-verify'
89
90 - job-template:
91     name: 'genesis-{installer}-merge'
92
93     # builder-merge job to run JJB update
94     #
95     # This job's purpose is to update all the JJB
96
97     project-type: freestyle
98
99     node: ericsson-build
100
101     logrotate:
102         daysToKeep: 30
103         numToKeep: 40
104         artifactDaysToKeep: -1
105         artifactNumToKeep: 5
106
107     parameters:
108         - string:
109             name: BUILD_DIRECTORY
110             default: $WORKSPACE/build_output
111         - string:
112             name: GIT_BASE
113             default: https://gerrit.opnfv.org/gerrit/genesis
114         - project-parameter:
115             project: '{project}'
116         - gerrit-parameter:
117             branch: 'master'
118
119     scm:
120         - gerrit-trigger-scm:
121             credentials-id: '{ssh-credentials}'
122             refspec: ''
123             choosing-strategy: 'default'
124
125     wrappers:
126         - ssh-agent-credentials:
127             user: '{ssh-credentials}'
128
129     triggers:
130         - gerrit:
131             trigger-on:
132                 - change-merged-event
133                 - comment-added-contains-event:
134                     comment-contains-value: 'remerge'
135             projects:
136               - project-compare-type: 'ANT'
137                 project-pattern: 'genesis'
138                 branches:
139                     - branch-compare-type: 'ANT'
140                       branch-pattern: '**/master'
141                 file-paths:
142                   - compare-type: ANT
143                     pattern: 'common/**'
144                   - compare-type: ANT
145                     pattern: '{installer}/**'
146
147     builders:
148         - '{installer}-merge'
149
150 - job-template:
151     name: 'genesis-{installer}-daily-master'
152
153     project-type: freestyle
154
155     node: ericsson-build
156
157     parameters:
158         - string:
159             name: BUILD_DIRECTORY
160             default: $WORKSPACE/build_output
161         - string:
162             name: INSTALLER
163             default: '{installer}'
164             description: "Installer to use."
165         - string:
166             name: GIT_BASE
167             default: https://gerrit.opnfv.org/gerrit/genesis
168         - string:
169             name: GERRIT_BRANCH
170             default: origin/master
171             description: "Branch to build, deploy and test."
172         - string:
173             name: GERRIT_REFSPEC
174             default: refs/heads/master
175             description: "Refspec to retrieve."
176
177     scm:
178         - git:
179             skip-tag: true
180             url: $GIT_BASE
181             branches:
182                 - $GERRIT_BRANCH
183             refspec: $GERRIT_REFSPEC
184
185     triggers:
186         - pollscm: '@midnight'
187
188     logrotate:
189         daysToKeep: 30
190         numToKeep: 10
191         artifactDaysToKeep: -1
192         artifactNumToKeep: -1
193
194     builders:
195         - '{installer}-daily-master'
196
197 ########################
198 # builder macros
199 ########################
200 - builder:
201     name: foreman-verify
202     builders:
203         - shell: |
204             #!/bin/bash
205
206             echo "Hello World!"
207
208 - builder:
209     name: foreman-merge
210     builders:
211         - shell: |
212             #!/bin/bash
213
214             echo "Hello World!"
215
216 - builder:
217     name: foreman-daily-master
218     builders:
219         - shell: |
220             #!/bin/bash
221
222             echo "Hello World!"
223
224 - builder:
225     name: fuel-verify
226     builders:
227         - shell: |
228             #!/bin/bash
229             set -o errexit
230             set -o nounset
231             set -o pipefail
232             set -x
233
234             # set/create the cache location
235             OPNFV_FUEL_CACHE="$(dirname $WORKSPACE)/opnfv_fuel_cache"
236             [[ -d $OPNFV_FUEL_CACHE ]] || mkdir -p $OPNFV_FUEL_CACHE
237
238             # do the build
239             cd $WORKSPACE/fuel/ci
240             ./build.sh -c file://$OPNFV_FUEL_CACHE $BUILD_DIRECTORY
241
242             # list the build artifacts
243             ls -al $BUILD_DIRECTORY
244
245 - builder:
246     name: fuel-merge
247     builders:
248         - shell: |
249             #!/bin/bash
250             set -o errexit
251             set -o nounset
252             set -o pipefail
253             set -x
254
255             # set/create the cache location
256             OPNFV_FUEL_CACHE="$(dirname $WORKSPACE)/opnfv_fuel_cache"
257             [[ -d $OPNFV_FUEL_CACHE ]] || mkdir -p $OPNFV_FUEL_CACHE
258
259             # do the build
260             cd $WORKSPACE/fuel/ci
261             ./build.sh -c file://$OPNFV_FUEL_CACHE $BUILD_DIRECTORY
262
263             # list the build artifacts
264             ls -al $BUILD_DIRECTORY
265
266 - builder:
267     name: fuel-daily-master
268     builders:
269         - shell: |
270             #!/bin/bash
271             set -o errexit
272             set -o nounset
273             set -o pipefail
274             set -x
275
276             # set/create the cache location
277             OPNFV_FUEL_CACHE="$(dirname $WORKSPACE)/opnfv_fuel_cache"
278             [[ -d $OPNFV_FUEL_CACHE ]] || mkdir -p $OPNFV_FUEL_CACHE
279
280             # do the build
281             cd $WORKSPACE/fuel/ci
282             ./build.sh -f t -c file://$OPNFV_FUEL_CACHE $BUILD_DIRECTORY
283
284             # list the build artifacts
285             ls -al $BUILD_DIRECTORY
286
287 - builder:
288     name: opensteak-verify
289     builders:
290         - shell: |
291             #!/bin/bash
292
293             echo "Hello World!"
294
295 - builder:
296     name: opensteak-merge
297     builders:
298         - shell: |
299             #!/bin/bash
300
301             echo "Hello World!"
302
303 - builder:
304     name: opensteak-daily-master
305     builders:
306         - shell: |
307             #!/bin/bash
308
309             echo "Hello World!"