83593727b51c9837bdc2c34fe4e8b1ce92dc69c9
[ci-management.git] / jjb / global-templates-script.yaml
1 ---
2 # vim: sw=2 ts=2 sts=2 et :
3
4 - job-template:
5     # Job template for basic scm and script trigger
6     #
7     # Required Variables:
8     #   branch:         git branch
9     #   build-node:     what build node to run on
10     #   script:         build script to execute
11
12     name: '{project-name}-{stream}-verify-script'
13
14     project-type: freestyle
15     concurrent: true
16     node: '{build-node}'
17
18     properties:
19       - ecomp-infra-properties:
20           build-days-to-keep: '{build-days-to-keep}'
21
22     parameters:
23       - ecomp-infra-parameters:
24           project: '{project}'
25           branch: '{branch}'
26           refspec: 'refs/heads/{branch}'
27           artifacts: '{archive-artifacts}'
28       - maven-exec:
29           maven-version: 'mvn33'
30
31     scm:
32       - gerrit-trigger-scm:
33           refspec: '$GERRIT_REFSPEC'
34           choosing-strategy: 'gerrit'
35
36     wrappers:
37       - ecomp-infra-wrappers:
38           build-timeout: '{build-timeout}'
39
40     triggers:
41       - gerrit-trigger-patch-submitted:
42           server: '{server-name}'
43           project: '{project}'
44           branch: '{branch}'
45           files: '**'
46
47     builders:
48       - provide-maven-settings:
49           global-settings-file: 'global-settings'
50           settings-file: '{mvn-settings}'
51       # make sure maven gets installed / setup
52       - maven-target:
53           maven-version: 'mvn33'
54           goals: '--version'
55           settings: '{mvn-settings}'
56           settings-type: cfp
57           global-settings: 'global-settings'
58           global-settings-type: cfp
59       - shell: '{script}'
60
61 #    publishers:
62 #      - ecomp-infra-shiplogs:
63 #          maven-version: 'mvn33'
64
65 - job-template:
66     # Job template for 2 scm and script trigger
67     #
68     # Required Variables:
69     #   branch:         git branch
70     #   build-node:     what build node to run on
71     #   script:         build script to execute
72     #   extra-project:  extra gerrit project to checkout
73     #   extra-refspec:  refspec for the extra project
74     #   extra-branch:   branch to checkout for the extra project
75     #   checkout-dir:   directory to checkout the extra project to
76     #                     DO NOT SET THIS TO anything that translates to
77     #                     $WORKSPACE as it will destroy the initial
78     #                     project checkout
79
80     name: '{project-name}-{stream}-two-scm-verify-script'
81
82     project-type: freestyle
83     concurrent: true
84     node: '{build-node}'
85
86     properties:
87       - ecomp-infra-properties:
88           build-days-to-keep: '{build-days-to-keep}'
89
90     parameters:
91       - ecomp-infra-parameters:
92           project: '{project}'
93           branch: '{branch}'
94           refspec: 'refs/heads/{branch}'
95           artifacts: '{archive-artifacts}'
96       - maven-exec:
97           maven-version: 'mvn33'
98
99     scm:
100       - gerrit-trigger-scm:
101           refspec: '$GERRIT_REFSPEC'
102           choosing-strategy: 'gerrit'
103       - git-extra-project:
104           project: '{extra-project}'
105           refspec: '{extra-refspec}'
106           branch: '{extra-branch}'
107           checkout-dir: '{checkout-dir}'
108
109     wrappers:
110       - ecomp-infra-wrappers:
111           build-timeout: '{build-timeout}'
112
113     triggers:
114       - gerrit-trigger-patch-submitted:
115           server: '{server-name}'
116           project: '{project}'
117           branch: '{branch}'
118           files: '**'
119
120     builders:
121       - provide-maven-settings:
122           global-settings-file: 'global-settings'
123           settings-file: '{mvn-settings}'
124       # make sure maven gets installed / setup
125       - maven-target:
126           maven-version: 'mvn33'
127           goals: '--version'
128           settings: '{mvn-settings}'
129           settings-type: cfp
130           global-settings: 'global-settings'
131           global-settings-type: cfp
132       - shell: '{script}'
133
134 #    publishers:
135 #      - ecomp-infra-shiplogs:
136 #          maven-version: 'mvn33'
137
138
139 - job-template:
140     # Job template for 3 scm and script trigger
141     #
142     # Required Variables:
143     #   branch:         git branch
144     #   build-node:     what build node to run on
145     #   script:         build script to execute
146     #   extra-project1:  extra gerrit project to checkout
147     #   extra-refspec1:  refspec for the extra project
148     #   extra-branch1:   branch to checkout for the extra project
149     #   checkout-dir1:   directory to checkout the extra project to
150     #                     DO NOT SET THIS TO anything that translates to
151     #                     $WORKSPACE as it will destroy the initial
152     #                     project checkout
153     #   extra-project2:  extra gerrit project to checkout
154     #   extra-refspec2:  refspec for the extra project
155     #   extra-branch2:   branch to checkout for the extra project
156     #   checkout-dir2:   directory to checkout the extra project to
157     #                     DO NOT SET THIS TO anything that translates to
158     #                     $WORKSPACE as it will destroy the initial
159     #                     project checkout
160     name: '{project-name}-{stream}-three-scm-verify-script'
161
162     project-type: freestyle
163     concurrent: true
164     node: '{build-node}'
165
166     properties:
167       - ecomp-infra-properties:
168           build-days-to-keep: '{build-days-to-keep}'
169
170     parameters:
171       - ecomp-infra-parameters:
172           project: '{project}'
173           branch: '{branch}'
174           refspec: 'refs/heads/{branch}'
175           artifacts: '{archive-artifacts}'
176       - maven-exec:
177           maven-version: 'mvn33'
178
179     scm:
180       - gerrit-trigger-scm:
181           refspec: '$GERRIT_REFSPEC'
182           choosing-strategy: 'gerrit'
183       - git-extra-project:
184           project: '{extra-project1}'
185           refspec: '{extra-refspec1}'
186           branch: '{extra-branch1}'
187           checkout-dir: '{checkout-dir1}'
188       - git-extra-project:
189           project: '{extra-project2}'
190           refspec: '{extra-refspec2}'
191           branch: '{extra-branch2}'
192           checkout-dir: '{checkout-dir2}'
193
194     wrappers:
195       - ecomp-infra-wrappers:
196           build-timeout: '{build-timeout}'
197
198     triggers:
199       - gerrit-trigger-patch-submitted:
200           server: '{server-name}'
201           project: '{project}'
202           branch: '{branch}'
203           files: '**'
204
205     builders:
206       - provide-maven-settings:
207           global-settings-file: 'global-settings'
208           settings-file: '{mvn-settings}'
209       # make sure maven gets installed / setup
210       - maven-target:
211           maven-version: 'mvn33'
212           goals: '--version'
213           settings: '{mvn-settings}'
214           settings-type: cfp
215           global-settings: 'global-settings'
216           global-settings-type: cfp
217       - shell: '{script}'
218
219 #    publishers:
220 #      - ecomp-infra-shiplogs:
221 #          maven-version: 'mvn33'