ONAP: Handle MVN settings.xml file as part of project build
[infra/cicd.git] / jjb / onap / global-templates-local-onap-java.yaml
1 ---
2 # This is a separate java verify template for the local ONAP repositories
3 # that are not push to ONAP upstream. 
4 - job-template:
5     name: 'local-onap-{project-name}-{stream}-verify-java'
6     disabled_job_var: false
7     node: onap-ubuntu1804
8
9     disabled: '{obj:disabled_job_var}'
10     concurrent: true
11     mvn_settings_xml_version:
12     properties:
13       - logrotate
14
15     parameters:
16       - project-parameters:
17           project: 'local/onap/{project}'
18           branch: '{branch}'
19       - nordix-gerrit-parameters
20       - string:
21           name: JAVA_HOME
22           default: '/usr/lib/jvm/{jdk-version}-openjdk-amd64'
23           description: Java home
24       - string:
25           name: MVN_VERSION
26           default: 3.5.4
27           description: Maven version
28       - string:
29           name: MVN_URL
30           default: https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/$MVN_VERSION/apache-maven-${{MVN_VERSION}}-bin.zip
31           description: URL to download Maven
32       - string:
33           name: MVN
34           default: $WORKSPACE/apache-maven-${{MVN_VERSION}}/bin/mvn
35           description: Path to mvn executable
36       - string:
37           name: MVN_SETTINGS_XML_VERSION
38           default: '{mvn_settings_xml_version}'
39           description: Commit ID of ONAP Oparent repository (https://git.onap.org/oparent/) to pull. Used for Maven settings file. Can be left blank to pull the latest version.
40
41     scm:
42       - git-scm-gerrit:
43           ssh-credentials-id: nordixinfra-nordix-gerrit-ssh
44           branch: '{branch}'
45           refspec: $GERRIT_REFSPEC
46           wipe_workspace: true
47           clean_before: false
48
49     triggers:
50       - nordix-gerrit-trigger-patchset-created:
51           project: 'local/onap/{project}'
52           branch: '{branch}'
53           files: '**'
54
55     wrappers:
56       - build-timeout:
57           timeout: 45
58
59     builders:
60       - shell:
61           !include-raw-escape: ./verify-jobs.sh