cloud-infra: Fix triggers for docs jobs
[infra/cicd.git] / jjb / cloud-infra / cloud-infra-docs.yaml
1 ---
2 # ============LICENSE_START=======================================================
3 #  Copyright (C) 2019 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
20 - project:
21     name: 'cloud-infra-docs'
22
23     project: 'cloud-infra-docs'
24
25     stream:
26       - 'master':
27           branch: '{stream}'
28           disabled: false
29
30     jobs:
31       - 'cloud-infra-verify-docs-{stream}'
32       - 'cloud-infra-merge-docs-{stream}'
33
34 - job-template:
35     name: 'cloud-infra-verify-docs-{stream}'
36
37     disabled: '{obj:disabled}'
38
39     concurrent: true
40
41     node: 'infra-tools-docker-slave-ubuntu1804'
42
43     parameters:
44       - project-parameters:
45           project: $GERRIT_PROJECT
46           branch: '{branch}'
47       - nordix-gerrit-parameters
48       - string:
49           name: LINT_TYPE
50           default: 'docs'
51           description: 'Lint type to run'
52
53     properties:
54       - logrotate
55
56     wrappers:
57       - build-timeout:
58           timeout: 150
59       - fix-workspace-permissions
60
61     scm:
62       - git-scm-gerrit:
63           ssh-credentials-id: nordixinfra-nordix-gerrit-ssh
64           branch: '{branch}'
65           refspec: $GERRIT_REFSPEC
66           wipe_workspace: true
67           clean_before: false
68
69     triggers:
70       - nordix-gerrit-trigger-patchset-created:
71           project: 'infra\/engine|infra\/docs'
72           branch: '{branch}'
73           files: 'docs/**'
74           skip-vote:
75             successful: false
76             failed: false
77             unstable: false
78             notbuilt: false
79           custom-url: '* $JOB_NAME $BUILD_URL'
80
81     builders:
82       - 'cloud-infra-lint-macro'
83
84 - job-template:
85     name: 'cloud-infra-merge-docs-{stream}'
86
87     disabled: '{obj:disabled}'
88
89     concurrent: false
90
91     node: 'infra-docs-build'
92
93     parameters:
94       - project-parameters:
95           project: $GERRIT_PROJECT
96           branch: '{branch}'
97       - nordix-gerrit-parameters
98       - string:
99           name: LINT_TYPE
100           default: 'docs-deploy'
101           description: 'Lint type to run'
102
103     properties:
104       - logrotate
105
106     wrappers:
107       - build-timeout:
108           timeout: 150
109       - fix-workspace-permissions
110
111     scm:
112       - git-scm:
113           ssh-credentials-id: nordixinfra-nordix-gerrit-ssh
114           branch: '{branch}'
115           refspec: ''
116           wipe_workspace: true
117           clean_before: false
118
119     triggers:
120       - nordix-gerrit-trigger-change-merged:
121           project: 'infra\/docs'
122           branch: '{branch}'
123           files: 'docs/**'
124           custom-url: '* $JOB_NAME $BUILD_URL'
125
126     wrappers:
127       - nordixinfra-jjb-creds-wrapper
128
129     builders:
130       - 'cloud-infra-lint-macro'
131
132 # vim: set ts=2 sw=2 expandtab: