---
# This file contains job templates for Maven projects.
-- job-group:
- name: '{project-name}-maven-jobs'
-
- # This job group contains all the recommended jobs that should be deployed
- # for any project ci.
-
- # TODO: Add Maven Merge job to this list once it's been fully tested.
- jobs:
- - gerrit-maven-clm
- - gerrit-maven-merge
- - gerrit-maven-stage
- - gerrit-maven-verify
- - gerrit-maven-verify-dependencies
-
-- job-group:
- name: '{project-name}-github-maven-jobs'
-
- # This job group contains all the recommended jobs that should be deployed
- # for any project ci that is using github.
-
- # TODO: Add Maven Merge job to this list once it's been fully tested.
- jobs:
- - github-maven-clm
- - github-maven-merge
- - github-maven-stage
- - github-maven-verify
-
-- job-group:
- name: '{project-name}-maven-javadoc-jobs'
-
- # This job group contains all the recommended jobs that should be deployed
- # for any project ci.
-
- jobs:
- - gerrit-maven-javadoc-publish
- - gerrit-maven-javadoc-verify
-
-- job-group:
- name: '{project-name}-github-maven-javadoc-jobs'
-
- # This job group contains all the recommended jobs that should be deployed
- # for any project ci.
-
- jobs:
- - github-maven-javadoc-publish
- - github-maven-javadoc-verify
-
##########
# Macros #
##########
project: '{project}'
branch: '{branch}'
stream: '{stream}'
- lftools-version: '{lftools-version}'
- lf-infra-maven-parameters:
mvn-opts: '{mvn-opts}'
mvn-params: '{mvn-params}'
branch: master
build-days-to-keep: 30 # 30 days for troubleshooting purposes
build-timeout: 60
+ disable-job: false
git-url: '$GIT_URL/$PROJECT'
github-url: 'https://github.com'
java-version: openjdk8
mvn-opts: ''
mvn-params: ''
mvn-version: mvn35
+ nexus-iq-namespace: '' # Recommend a trailing dash when set. Example: odl-
nexus-iq-stage: 'build'
stream: master
submodule-recursive: true
+ submodule-timeout: 10
nexus_iq_scan_patterns:
- '**/*.ear'
project: '{project}'
branch: '{branch}'
stream: '{stream}'
- lftools-version: '{lftools-version}'
- lf-infra-maven-parameters:
mvn-opts: '{mvn-opts}'
mvn-params: '{mvn-params}'
# Job Configuration #
#####################
+ disabled: '{disable-job}'
+
builders:
+ - lf-infra-pre-build
- lf-maven-install:
mvn-version: '{mvn-version}'
- lf-update-java-alternatives:
- nexus-iq-policy-evaluator:
stage: '{nexus-iq-stage}'
application-type: 'manual'
- application-id: '{project-name}'
+ application-id: '{nexus-iq-namespace}{project-name}'
scan-patterns: '{obj:nexus_iq_scan_patterns}'
fail-build-network-error: true
refspec: '$GERRIT_REFSPEC'
branch: '$GERRIT_BRANCH'
submodule-recursive: '{submodule-recursive}'
+ submodule-timeout: '{submodule-timeout}'
choosing-strategy: default
triggers:
refspec: ''
branch: 'refs/heads/{branch}'
submodule-recursive: '{submodule-recursive}'
+ submodule-timeout: '{submodule-timeout}'
choosing-strategy: default
jenkins-ssh-credential: '{jenkins-ssh-credential}'
branch: master
build-days-to-keep: 30 # 30 days in case a release takes long to get approved.
build-timeout: 60
+ disable-job: false
git-url: '$GIT_URL/$PROJECT'
github-url: 'https://github.com'
java-version: openjdk8
mvn-version: mvn35
stream: master
submodule-recursive: true
+ submodule-timeout: 10
gerrit_merge_triggers:
- change-merged-event
# Job Configuration #
#####################
+ disabled: '{disable-job}'
+
builders:
+ - lf-infra-pre-build
- lf-maven-install:
mvn-version: '{mvn-version}'
- lf-update-java-alternatives:
- shell: !include-raw-escape:
- ../shell/common-variables.sh
- ../shell/maven-javadoc-generate.sh
- - ../shell/lftools-install.sh
- ../shell/maven-javadoc-publish.sh
- lf-provide-maven-settings-cleanup
refspec: ''
branch: '{branch}'
submodule-recursive: '{submodule-recursive}'
+ submodule-timeout: '{submodule-timeout}'
choosing-strategy: default
jenkins-ssh-credential: '{jenkins-ssh-credential}'
refspec: ''
branch: '{branch}'
submodule-recursive: '{submodule-recursive}'
+ submodule-timeout: '{submodule-timeout}'
choosing-strategy: default
jenkins-ssh-credential: '{jenkins-ssh-credential}'
trigger-phrase: '^remerge$'
only-trigger-phrase: true
status-context: 'Maven Javadoc Publish'
- permit-all: false
+ permit-all: true
github-hooks: true
org-list:
- '{github-org}'
branch: master
build-days-to-keep: 30 # 30 days in case a release takes long to get approved.
build-timeout: 60
+ disable-job: false
git-url: '$GIT_URL/$PROJECT'
github-url: 'https://github.com'
java-version: openjdk8
mvn-version: mvn35
stream: master
submodule-recursive: true
+ submodule-timeout: 10
gerrit_verify_triggers:
- patchset-created-event:
#####################
concurrent: true
+ disabled: '{disable-job}'
builders:
+ - lf-infra-pre-build
- lf-maven-install:
mvn-version: '{mvn-version}'
- lf-update-java-alternatives:
refspec: '$GERRIT_REFSPEC'
branch: '$GERRIT_BRANCH'
submodule-recursive: '{submodule-recursive}'
+ submodule-timeout: '{submodule-timeout}'
choosing-strategy: gerrit
triggers:
refspec: '+refs/pull/*:refs/remotes/origin/pr/*'
branch: '$sha1'
submodule-recursive: '{submodule-recursive}'
+ submodule-timeout: '{submodule-timeout}'
choosing-strategy: default
jenkins-ssh-credential: '{jenkins-ssh-credential}'
build-days-to-keep: 30 # 30 days in case we need to troubleshoot
build-timeout: 60
cron: '@daily'
+ disable-job: false
git-url: '$GIT_URL/$PROJECT'
github-url: 'https://github.com'
java-version: openjdk8
nexus-cut-dirs: 6 # Number of dirs in the Nexus path to remove for wget -r.
stream: master
submodule-recursive: true
+ submodule-timeout: 10
gerrit_merge_triggers:
- change-merged-event
# Job Configuration #
#####################
+ disabled: '{disable-job}'
+
builders:
+ - lf-infra-pre-build
- lf-jacoco-nojava-workaround
- lf-maven-install:
mvn-version: '{mvn-version}'
properties-content: |
NEXUS_CUT_DIRS={nexus-cut-dirs}
NEXUS_REPO={nexus-snapshot-repo}
- - shell: !include-raw-escape:
- - ../shell/lftools-install.sh
- - ../shell/maven-fetch-metadata.sh
+ - shell: !include-raw-escape: ../shell/maven-fetch-metadata.sh
- lf-maven-build:
mvn-goals: '{mvn-goals}'
- lf-maven-deploy
refspec: '$GERRIT_REFSPEC'
branch: '$GERRIT_BRANCH'
submodule-recursive: '{submodule-recursive}'
+ submodule-timeout: '{submodule-timeout}'
choosing-strategy: default
triggers:
scm:
- lf-infra-github-scm:
url: '{git-clone-url}{github-org}/{project}'
- refspec: '+refs/pull/*:refs/remotes/origin/pr/*'
- branch: '{branch}'
+ refspec: ''
+ branch: 'refs/heads/{branch}'
submodule-recursive: '{submodule-recursive}'
+ submodule-timeout: '{submodule-timeout}'
choosing-strategy: default
jenkins-ssh-credential: '{jenkins-ssh-credential}'
trigger-phrase: '^remerge$'
only-trigger-phrase: true
status-context: 'Maven Merge'
- permit-all: false
+ permit-all: true
github-hooks: true
org-list:
- '{github-org}'
build-days-to-keep: 30 # 30 days in case a release takes long to get approved.
build-timeout: 60
cron: '@daily'
+ disable-job: false
git-url: '$GIT_URL/$PROJECT'
github-url: 'https://github.com'
java-version: openjdk8
+ mvn-central: false
mvn-global-settings: global-settings
mvn-goals: clean deploy
mvn-opts: ''
mvn-params: ''
mvn-version: mvn35
+ ossrh-profile-id: ''
+ sign-artifacts: false
stream: master
submodule-recursive: true
+ submodule-timeout: 10
gerrit_release_triggers:
- comment-added-contains-event:
# Job Configuration #
#####################
+ disabled: '{disable-job}'
+
parameters:
- lf-infra-parameters:
project: '{project}'
branch: '{branch}'
stream: '{stream}'
- lftools-version: '{lftools-version}'
- lf-infra-maven-parameters:
mvn-opts: '{mvn-opts}'
mvn-params: '{mvn-params}'
description: Nexus staging profile ID.
builders:
+ - lf-infra-pre-build
- lf-jacoco-nojava-workaround
- lf-maven-install:
mvn-version: '{mvn-version}'
settings-file: '{mvn-settings}'
- lf-infra-create-netrc:
server-id: '{mvn-staging-id}'
- - shell: !include-raw-escape:
- - ../shell/lftools-install.sh
- - ../shell/maven-patch-release.sh
+ - shell: !include-raw-escape: ../shell/maven-patch-release.sh
- lf-maven-build:
mvn-goals: '{mvn-goals}'
+ - lf-sigul-sign-dir:
+ sign-artifacts: '{sign-artifacts}'
+ sign-dir: '$WORKSPACE/m2repo'
- lf-maven-stage
+ - lf-maven-central:
+ mvn-central: '{mvn-central}'
+ ossrh-profile-id: '{ossrh-profile-id}'
- lf-provide-maven-settings-cleanup
- job-template:
refspec: '$GERRIT_REFSPEC'
branch: '$GERRIT_BRANCH'
submodule-recursive: '{submodule-recursive}'
+ submodule-timeout: '{submodule-timeout}'
choosing-strategy: default
triggers:
refspec: '+refs/pull/*:refs/remotes/origin/pr/*'
branch: '{branch}'
submodule-recursive: '{submodule-recursive}'
+ submodule-timeout: '{submodule-timeout}'
choosing-strategy: default
jenkins-ssh-credential: '{jenkins-ssh-credential}'
build-days-to-keep: 7
build-timeout: 60
cron: 'H H * * 6' # run weekly
+ disable-job: false
git-url: '$GIT_URL/$PROJECT'
github-url: 'https://github.com'
java-version: openjdk8
sonar-mvn-goal: 'sonar:sonar'
stream: master
submodule-recursive: true
+ submodule-timeout: 10
gerrit_sonar_triggers:
- comment-added-contains-event:
# Job Configuration #
#####################
+ disabled: '{disable-job}'
+
parameters:
- lf-infra-parameters:
project: '{project}'
branch: '{branch}'
stream: '{stream}'
- lftools-version: '{lftools-version}'
- lf-infra-maven-parameters:
mvn-opts: '{mvn-opts}'
mvn-params: '{mvn-params}'
notbuilt: true
builders:
+ - lf-infra-pre-build
- lf-infra-maven-sonar:
java-version: '{java-version}'
mvn-settings: '{mvn-settings}'
refspec: $GERRIT_REFSPEC
branch: $GERRIT_BRANCH
submodule-recursive: '{submodule-recursive}'
+ submodule-timeout: '{submodule-timeout}'
choosing-strategy: default
- job-template:
refspec: '+refs/pull/*:refs/remotes/origin/pr/*'
branch: '$sha1'
submodule-recursive: '{submodule-recursive}'
+ submodule-timeout: '{submodule-timeout}'
choosing-strategy: default
jenkins-ssh-credential: '{jenkins-ssh-credential}'
triggers:
+ # Build weekly on Saturdays
+ - timed: 'H H * * 6'
- github-pull-request:
trigger-phrase: '^run-sonar$'
- only-trigger-phrase: false
+ only-trigger-phrase: true
status-context: 'Maven Sonar'
permit-all: true
github-hooks: true
+ org-list:
+ - '{github-org}'
+ white-list: '{obj:github_pr_whitelist}'
+ admin-list: '{obj:github_pr_admin_list}'
white-list-target-branches:
- '{branch}'
branch: master
build-days-to-keep: 7
build-timeout: 60
+ disable-job: false
git-url: '$GIT_URL/$PROJECT'
github-url: 'https://github.com'
java-version: openjdk8
mvn-version: mvn35
stream: master
submodule-recursive: true
+ submodule-timeout: 10
gerrit_verify_triggers:
- patchset-created-event:
#####################
concurrent: true
+ disabled: '{disable-job}'
builders:
+ - lf-infra-pre-build
- lf-jacoco-nojava-workaround
- lf-maven-install:
mvn-version: '{mvn-version}'
- lf-provide-maven-settings:
global-settings-file: '{mvn-global-settings}'
settings-file: '{mvn-settings}'
- - shell: !include-raw-escape:
- - ../shell/lftools-install.sh
- lf-maven-build:
mvn-goals: '{mvn-goals}'
- lf-provide-maven-settings-cleanup
refspec: '$GERRIT_REFSPEC'
branch: '$GERRIT_BRANCH'
submodule-recursive: '{submodule-recursive}'
+ submodule-timeout: '{submodule-timeout}'
choosing-strategy: gerrit
triggers:
refspec: '+refs/pull/*:refs/remotes/origin/pr/*'
branch: '$sha1'
submodule-recursive: '{submodule-recursive}'
+ submodule-timeout: '{submodule-timeout}'
choosing-strategy: default
jenkins-ssh-credential: '{jenkins-ssh-credential}'
branch: master
build-days-to-keep: 7
build-timeout: 60
+ disable-job: false
git-url: '$GIT_URL/$PROJECT'
github-url: 'https://github.com'
java-version: openjdk8
mvn-version: mvn35
stream: master
submodule-recursive: true
+ submodule-timeout: 10
gerrit_verify_triggers:
- comment-added-contains-event:
#####################
concurrent: true
+ disabled: '{disable-job}'
builders:
+ - lf-infra-pre-build
- lf-jacoco-nojava-workaround
- lf-maven-install:
mvn-version: '{mvn-version}'
refspec: '$GERRIT_REFSPEC'
branch: '$GERRIT_BRANCH'
submodule-recursive: '{submodule-recursive}'
+ submodule-timeout: '{submodule-timeout}'
choosing-strategy: gerrit
triggers: