Merge "jjb: Add airship ci unit test pipeline"
[infra/cicd.git] / jjb / nolabs / nolabs-jobs.yaml
1 ---
2 #
3 # ============LICENSE_START=======================================================
4 #  Copyright (C) 2019 Nordix Foundation.
5 # ================================================================================
6 # Licensed under the Apache License, Version 2.0 (the "License");
7 # you may not use this file except in compliance with the License.
8 # You may obtain a copy of the License at
9 #
10 #      http://www.apache.org/licenses/LICENSE-2.0
11 #
12 # Unless required by applicable law or agreed to in writing, software
13 # distributed under the License is distributed on an "AS IS" BASIS,
14 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 # See the License for the specific language governing permissions and
16 # limitations under the License.
17 #
18 # SPDX-License-Identifier: Apache-2.0
19 # ============LICENSE_END=========================================================
20
21 - project:
22     name: 'nolabs'
23
24     project: 'nolabs'
25
26     stream:
27       - 'master':
28           branch: '{stream}'
29
30     jobs:
31       - 'nolabs-verify-{stream}'
32       - 'nolabs-deploy-{stream}'
33
34 - job-template:
35     name: 'nolabs-verify-{stream}'
36
37     concurrent: false
38
39     parameters:
40       - project-parameters:
41           project: '{project}'
42           branch: '{branch}'
43       - nordix-gerrit-parameters
44       - label:
45           name: SLAVE_LABEL
46           default: 'nolabs'
47           description: 'Slave label to schedule this job on.'
48
49     properties:
50       - logrotate
51       - build-blocker:
52           use-build-blocker: true
53           blocking-jobs:
54             - 'nolabs-.*'
55           block-level: 'NODE'
56       - throttle:
57           max-per-node: 1
58           max-total: 1
59           option: project
60
61     wrappers:
62       - build-timeout:
63           timeout: 10
64       - fix-workspace-permissions
65
66     scm:
67       - git-scm-gerrit:
68           ssh-credentials-id: nordixinfra-nordix-gerrit-ssh
69           branch: '{branch}'
70           refspec: $GERRIT_REFSPEC
71           wipe_workspace: true
72           clean_before: false
73
74     triggers:
75       - gerrit:
76           server-name: 'Nordix Gerrit'
77           trigger-on:
78             - patchset-created-event:
79                 exclude-drafts: 'false'
80                 exclude-trivial-rebase: 'false'
81                 exclude-no-code-change: 'false'
82             - draft-published-event
83             - comment-added-contains-event:
84                 comment-contains-value: 'recheck'
85             - comment-added-contains-event:
86                 comment-contains-value: 'reverify'
87           projects:
88             - project-compare-type: 'REG_EXP'
89               project-pattern: 'nolabs'
90               branches:
91                 - branch-compare-type: 'ANT'
92                   branch-pattern: '**/{branch}'
93               disable-strict-forbidden-file-verification: 'false'
94               forbidden-file-paths:
95                 - compare-type: ANT
96                   pattern: '.gitignore'
97                 - compare-type: ANT
98                   pattern: '.gitreview'
99
100     builders:
101       - shell:
102           !include-raw-escape: ./verify.sh
103
104 - job-template:
105     name: 'nolabs-deploy-{stream}'
106
107     concurrent: false
108
109     parameters:
110       - project-parameters:
111           project: '{project}'
112           branch: '{branch}'
113       - nordix-gerrit-parameters
114       - label:
115           name: SLAVE_LABEL
116           default: 'nolabs'
117           description: 'Slave label to schedule this job on.'
118
119     properties:
120       - logrotate
121       - build-blocker:
122           use-build-blocker: true
123           blocking-jobs:
124             - 'nolabs-.*'
125           block-level: 'NODE'
126       - throttle:
127           max-per-node: 1
128           max-total: 1
129           option: project
130
131     wrappers:
132       - build-timeout:
133           timeout: 10
134       - fix-workspace-permissions
135
136     scm:
137       - git-scm:
138           ssh-credentials-id: nordixinfra-nordix-gerrit-ssh
139           branch: '{branch}'
140           refspec: ''
141           wipe_workspace: true
142           clean_before: false
143
144     triggers:
145       - gerrit:
146           server-name: 'Nordix Gerrit'
147           trigger-on:
148             - change-merged-event
149             - comment-added-contains-event:
150                 comment-contains-value: 'remerge'
151           projects:
152             - project-compare-type: 'ANT'
153               project-pattern: '{project}'
154               branches:
155                 - branch-compare-type: 'ANT'
156                   branch-pattern: '**/{branch}'
157               disable-strict-forbidden-file-verification: 'false'
158               forbidden-file-paths:
159                 - compare-type: ANT
160                   pattern: '.gitignore'
161                 - compare-type: ANT
162                   pattern: '.gitreview'
163
164     builders:
165       - shell:
166           !include-raw-escape: ./deploy.sh
167
168 # vim: set ts=2 sw=2 expandtab: