INFRA: Switch to tox for JJB verify and merge jobs
[infra/cicd.git] / jjb / infra / jjb-merge-jobs.yaml
1 ---
2 # ============LICENSE_START=======================================================
3 #  Copyright (C) 2020 Nordix Foundation.
4 # ================================================================================
5 # Licensed under the Apache License, Version 2.0 (the "License");
6 # you may not use this file except in compliance with the License.
7 # You may obtain a copy of the License at
8 #
9 #      http://www.apache.org/licenses/LICENSE-2.0
10 #
11 # Unless required by applicable law or agreed to in writing, software
12 # distributed under the License is distributed on an "AS IS" BASIS,
13 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 # See the License for the specific language governing permissions and
15 # limitations under the License.
16 #
17 # SPDX-License-Identifier: Apache-2.0
18 # ============LICENSE_END=========================================================
19 # this job gets triggered when a change is merged in cicd/jjb
20 # the updates to the jobs are deployed to jenkins using jenkins-jobs update command
21 # executed from tox. The result will be send to Gerrit in the form of a comment
22 - project:
23     name: infra-jjb-merge
24     project: infra/cicd
25
26     stream:
27       - master:
28           branch: '{stream}'
29
30     lint-type: jjbdeploy
31     jobs:
32       - infra-merge-cicd-jjb-{stream}
33
34
35 - job-template:
36     name: infra-merge-cicd-jjb-{stream}
37     node: infra-tools-docker-slave-ubuntu1804
38     disabled: false
39     concurrent: false
40
41     parameters:
42       - project-parameters:
43           project: '{project}'
44           branch: '{branch}'
45           description: 'The project and branch which the change is proposed for'
46       - string:
47           name: LINT_TYPE
48           default: '{lint-type}'
49           description: 'Lint type to run'
50       - string:
51           name: VERBOSITY
52           default: 'false'
53           description: 'Verbosity setting for the lint script'
54       - nordix-gerrit-parameters
55
56     properties:
57       - logrotate
58
59     scm:
60       - git-scm:
61           ssh-credentials-id: nordixinfra-nordix-gerrit-ssh
62           branch: '{branch}'
63           refspec: ''
64           wipe_workspace: true
65           clean_before: false
66
67     triggers:
68       - nordix-gerrit-trigger-change-merged:
69           project: '{project}'
70           branch: '{branch}'
71           files: 'jjb/**'
72
73     wrappers:
74       - nordixinfra-jjb-creds-wrapper
75       - build-timeout:
76           timeout: 60
77       - fix-workspace-permissions
78
79     builders:
80       - shell:
81           !include-raw-escape: ./lint.sh