Table of Contents |
---|
Excerpt | ||
---|---|---|
| ||
STATUS: implemented as of 2017-11-15 |
...
Rather than listing a specification, a full example is provided below. Notice that all JSON members are optional:
Code Block | ||||
---|---|---|---|---|
| ||||
{ "jenkins": { "jdks": [ 8, 9 ], "operatingSystems": [ "windows", "linux" ], "archivePatterns": [ "**/sling/logs/error.log" ], "mavenGoal": "install", "additionalMavenParams": "-Dorg.ops4j.pax.url.mvn.repositories=http://repo.maven.apache.org/maven2@id=apache-releases,http://repository.apache.org/content/groups/snapshots-group@snapshots@noreleases@id=apache-snapshots", "upstreamProjects": [ "sling-org-apache-sling-starter" ], "rebuildFrequency": "@weekly", "enabled": false, "emailRecipients": [ "dev@sling.apache.org" ], "branches": { "master": { "nodeLabel": "git-websites", "additionalMavenParams": "-Ppublish-site -Dmsg=\"Automatic website deployment\"" } }, "sonarQubeEnabled": false, "sonarQubeUseAdditionalMavenParams": false, "sonarQubeAdditionalParams": "-PsonarQubeProfile" } } |
Description
JSON member | Type | Possible Values |
---|---|---|
jenkins.jdks | Array of Numbers | 8-22 |
jenkins.operatingSystems | Array of Strings |
|
Default Values
The following JSON members have default values. All others are just not set/empty. Just set them explicitly to a value, if the default does not fit your needs.
JSON member | Default value |
---|---|
jenkins.jdks |
|
jenkins.operatingSystems |
|
jenkins.rebuildFrequency |
|
jenkins.sonarQubeEnabled | true |
jenkins.sonarQubeUseAdditionalMavenParams | true |
(Source: https://github.com/apache/sling-tooling-jenkins/blob/master/vars/slingOsgiBundleBuild.groovy)
Samples
Building with multiple JDK versions and operating systems
Code Block | ||||
---|---|---|---|---|
| ||||
{
"jenkins": {
"jdks": [8, 11, 17],
"operatingSystems": ["linux", "windows"]
}
} |
The first JDK/Operating System is always the reference one (i.e. the one from which the build artifacts are deployed to the Maven repository and which are used for the SonarCloud execution)