3 # Copyright (c) 2018 AT&T Intellectual Property. All rights reserved.
5 # Licensed under the Apache License, Version 2.0 (the "License"); you may
6 # not use this file except in compliance with the License.
8 # You may obtain a copy of the License at
9 # http://www.apache.org/licenses/LICENSE-2.0
11 # Unless required by applicable law or agreed to in writing, software
12 # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
13 # 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.
18 id: akraino-project-stream-release-config
19 name: '{project-name}-{stream}-release-config'
21 ######################
22 # Default parameters #
23 ######################
28 **/target/**/feature.xml
29 **/target/failsafe-reports/failsafe-summary.xml
30 **/target/surefire-reports/*-output.txt
31 build-days-to-keep: 30
33 java-version: openjdk8
34 maven-repo-url: '$NEXUS_URL/content/repositories/snapshots'
35 mvn-global-settings: global-settings
39 nexus-shapshot-repo: snapshots
41 staging-profile-id: '' # Unused by this job.
43 submodule-recursive: true
44 upload-files-dir: /tmp/tardir
50 project-type: freestyle
54 - lf-infra-properties:
55 build-days-to-keep: '{build-days-to-keep}'
58 - lf-infra-parameters:
62 lftools-version: '{lftools-version}'
63 - lf-infra-maven-parameters:
64 mvn-opts: '{mvn-opts}'
65 mvn-params: '{mvn-params}'
66 mvn-version: '{mvn-version}'
67 # Staging repos do not make sense for CLM jobs so set it blank.
68 staging-profile-id: '{staging-profile-id}'
70 name: ARCHIVE_ARTIFACTS
71 default: '{archive-artifacts}'
72 description: Artifacts to archive to the logs server.
74 name: UPLOAD_FILES_PATH
75 default: '{upload-files-dir}'
76 description: File path to generate tarball and upload to repository.
80 build-timeout: '{build-timeout}'
81 jenkins-ssh-credential: '{jenkins-ssh-credential}'
83 gerrit_merge_triggers:
85 - comment-added-contains-event:
86 comment-contains-value: remerge$
88 gerrit_trigger_file_paths:
89 - compare-type: REG_EXP
93 - lf-infra-gerrit-scm:
94 jenkins-ssh-credential: '{jenkins-ssh-credential}'
95 git-url: '{git-url}/{project}.git'
98 submodule-recursive: '{submodule-recursive}'
99 submodule-timeout: '{submodule-timeout}'
100 submodule-disable: false
101 choosing-strategy: default
104 - timed: '{obj:cron}'
106 server-name: '{gerrit-server-name}'
107 trigger-on: '{obj:gerrit_merge_triggers}'
109 - project-compare-type: ANT
110 project-pattern: '{project}'
112 - branch-compare-type: ANT
113 branch-pattern: '**/{branch}'
114 file-paths: '{obj:gerrit_trigger_file_paths}'
118 - config-file-provider:
120 - file-id: lftoolsini
121 target: "$HOME/.config/lftools/lftools.ini"
122 - file-id: sigul-config
123 variable: SIGUL_CONFIG
124 - file-id: sigul-password
125 variable: SIGUL_PASSWORD
128 - file-id: signing-pubkey
129 variable: SIGNING_PUBKEY
130 - shell: !include-raw-escape: ../global-jjb/shell/sigul-configuration.sh
131 - shell: !include-raw-escape: ../global-jjb/shell/sigul-install.sh
133 mvn-version: '{mvn-version}'
134 - lf-update-java-alternatives:
135 java-version: '{java-version}'
136 - lf-provide-maven-settings:
137 global-settings-file: '{mvn-global-settings}'
138 settings-file: '{mvn-settings}'
139 - shell: !include-raw-escape:
140 - ../shell/make-tar.sh
141 - lf-infra-deploy-maven-file:
142 global-settings-file: '{mvn-global-settings}'
143 settings-file: '{mvn-settings}'
144 mvn-version: '{mvn-version}'
146 group-id: '{group-id}'
147 upload-files-dir: '{upload-files-dir}'
148 maven-repo-url: '{maven-repo-url}'
155 id: akraino-project-stream-stage-config
156 name: '{project-name}-{stream}-stage-config'
158 ######################
159 # Default parameters #
160 ######################
165 **/target/**/feature.xml
166 **/target/failsafe-reports/failsafe-summary.xml
167 **/target/surefire-reports/*-output.txt
168 build-days-to-keep: 14
172 git-url: '$GIT_URL/$PROJECT'
173 github-url: 'https://github.com'
174 java-version: openjdk8
175 mvn-global-settings: global-settings
176 mvn-goals: clean deploy
180 sign-artifacts: false
182 submodule-recursive: true
183 upload-files-dir: m2repo # expected by "lftools deploy nexus-stage"
185 #####################
186 # Job Configuration #
187 #####################
189 project-type: freestyle
193 - lf-infra-properties:
194 build-days-to-keep: '{build-days-to-keep}'
197 - lf-infra-parameters:
201 lftools-version: '{lftools-version}'
202 - lf-infra-maven-parameters:
203 mvn-opts: '{mvn-opts}'
204 mvn-params: '{mvn-params}'
205 mvn-version: '{mvn-version}'
206 staging-profile-id: '{staging-profile-id}'
208 name: ARCHIVE_ARTIFACTS
209 default: '{archive-artifacts}'
210 description: Artifacts to archive to the logs server.
212 name: UPLOAD_FILES_PATH
213 default: '{upload-files-dir}'
214 description: File path to generate tarball and upload to repository.
216 name: STAGING_PROFILE_ID
217 default: '{staging-profile-id}'
218 description: Nexus staging profile ID.
222 description: Mark this as a staging build.
226 build-timeout: '{build-timeout}'
227 jenkins-ssh-credential: '{jenkins-ssh-credential}'
229 gerrit_release_triggers:
230 - comment-added-contains-event:
231 comment-contains-value: stage-release$
233 disabled: '{disable-job}'
236 - lf-infra-gerrit-scm:
237 jenkins-ssh-credential: '{jenkins-ssh-credential}'
239 refspec: '$GERRIT_REFSPEC'
240 branch: '$GERRIT_BRANCH'
241 submodule-recursive: '{submodule-recursive}'
242 submodule-timeout: '{submodule-timeout}'
243 submodule-disable: false
244 choosing-strategy: default
247 - timed: '{obj:cron}'
249 server-name: '{gerrit-server-name}'
250 trigger-on: '{obj:gerrit_release_triggers}'
252 - project-compare-type: ANT
253 project-pattern: '{project}'
255 - branch-compare-type: ANT
256 branch-pattern: '**/{branch}'
260 - config-file-provider:
262 - file-id: lftoolsini
263 target: "$HOME/.config/lftools/lftools.ini"
264 - file-id: sigul-config
265 variable: SIGUL_CONFIG
266 - file-id: sigul-password
267 variable: SIGUL_PASSWORD
270 - file-id: signing-pubkey
271 variable: SIGNING_PUBKEY
272 - shell: !include-raw-escape: ../global-jjb/shell/sigul-configuration.sh
273 - shell: !include-raw-escape: ../global-jjb/shell/sigul-install.sh
274 - lf-jacoco-nojava-workaround
276 mvn-version: '{mvn-version}'
277 - lf-update-java-alternatives:
278 java-version: '{java-version}'
279 - lf-provide-maven-settings:
280 global-settings-file: '{mvn-global-settings}'
281 settings-file: '{mvn-settings}'
282 - lf-infra-create-netrc:
283 server-id: '{mvn-staging-id}'
284 - shell: !include-raw-escape:
285 - ../shell/make-tar.sh
287 sign-artifacts: '{sign-artifacts}'
288 sign-dir: '$WORKSPACE/m2repo'
291 - lf-provide-maven-settings-cleanup
297 id: akraino-project-stream-verify
298 name: '{project-name}-{stream}-verify'
301 build-days-to-keep: 30
304 project-type: freestyle
305 submodule-recursive: true
309 - lf-infra-properties:
310 build-days-to-keep: '{build-days-to-keep}'
313 - lf-infra-parameters:
317 lftools-version: '{lftools-version}'
320 name: ARCHIVE_ARTIFACTS
321 default: '{archive-artifacts}'
322 description: Artifacts to archive to the logs server.
326 build-timeout: '{build-timeout}'
327 jenkins-ssh-credential: '{jenkins-ssh-credential}'
330 - lf-infra-gerrit-scm:
331 jenkins-ssh-credential: '{jenkins-ssh-credential}'
332 git-url: '{git-url}/{project}.git'
333 refspec: '$GERRIT_REFSPEC'
334 branch: '$GERRIT_BRANCH'
335 submodule-recursive: '{submodule-recursive}'
336 submodule-timeout: '{submodule-timeout}'
337 submodule-disable: false
338 choosing-strategy: 'gerrit'
342 server-name: '{gerrit-server-name}'
344 - patchset-created-event:
345 exclude-drafts: 'false'
346 exclude-trivial-rebase: 'false'
347 exclude-no-code-change: 'false'
348 - change-merged-event
349 - draft-published-event
350 - comment-added-contains-event:
351 comment-contains-value: 'recheck'
352 - comment-added-contains-event:
353 comment-contains-value: 'reverify'
355 - project-compare-type: 'ANT'
356 project-pattern: '{project}'
358 - branch-compare-type: 'ANT'
359 branch-pattern: '**/{branch}'
363 disable-strict-forbidden-file-verification: 'true'
364 forbidden-file-paths:
367 readable-message: true
370 - shell: !include-raw-escape:
377 id: akraino-project-build-node-init
378 name: '{project-name}-{build-node}-init'
379 disabled: '{obj:disabled}'
383 - lf-infra-parameters:
389 default: '{build-node}'
390 node-eligibility: 'all'
393 gerrit_merge_triggers:
394 - change-merged-event
395 - comment-added-contains-event:
396 comment-contains-value: remerge$
398 gerrit_trigger_file_paths:
399 - compare-type: REG_EXP
400 pattern: 'global-jjb'
403 - lf-infra-gerrit-scm:
404 jenkins-ssh-credential: '{jenkins-ssh-credential}'
405 git-url: '{git-url}/{project}.git'
406 refspec: '$GERRIT_REFSPEC'
407 branch: '$GERRIT_BRANCH'
408 submodule-recursive: true
409 submodule-timeout: '{submodule-timeout}'
410 submodule-disable: false
411 choosing-strategy: default
415 server-name: '{gerrit-server-name}'
416 trigger-on: '{obj:gerrit_merge_triggers}'
418 - project-compare-type: ANT
419 project-pattern: '{project}'
421 - branch-compare-type: ANT
422 branch-pattern: '**/{branch}'
423 file-paths: '{obj:gerrit_trigger_file_paths}'
426 - description-setter:
427 description: "POD: $NODE_NAME"
431 sudo -E ./global-jjb/jenkins-init-scripts/init.sh
432 sudo chown jenkins:jenkins -R archives