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