You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@brooklyn.apache.org by tb...@apache.org on 2019/12/05 11:07:03 UTC
[brooklyn-server] branch master updated: Reuse local maven cache +
add PR comment trigger
This is an automated email from the ASF dual-hosted git repository.
tbouron pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/brooklyn-server.git
The following commit(s) were added to refs/heads/master by this push:
new b3c9759 Reuse local maven cache + add PR comment trigger
new 0a01c97 Merge pull request #1072 from tbouron/feature/jenkins
b3c9759 is described below
commit b3c975956fc508fb0a8d2828cf7342ad50e9cdca
Author: Thomas Bouron <th...@cloudsoftcorp.com>
AuthorDate: Thu Dec 5 10:24:34 2019 +0000
Reuse local maven cache + add PR comment trigger
---
Jenkinsfile | 12 ++++++++----
1 file changed, 8 insertions(+), 4 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index 05aca28..50bc00b 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -18,6 +18,12 @@
*/
node(label: 'ubuntu') {
+ properties([
+ pipelineTriggers([
+ issueCommentTrigger('.*test this please.*')
+ ])
+ ])
+
catchError {
def environmentDockerImage
@@ -36,7 +42,7 @@ node(label: 'ubuntu') {
}
stage('Run tests') {
- environmentDockerImage.inside('-i --name brooklyn-${DOCKER_TAG} --mount type=bind,source="${HOME}/.m2/settings.xml",target=/var/maven/.m2/settings.xml,readonly -v ${WORKSPACE}:/usr/build -w /usr/build') {
+ environmentDockerImage.inside('-i --name brooklyn-${DOCKER_TAG} -v ${WORKSPACE}/.m2:/var/maven/.m2 --mount type=bind,source="${HOME}/.m2/settings.xml",target=/var/maven/.m2/settings.xml,readonly -v ${WORKSPACE}:/usr/build -w /usr/build') {
sh 'mvn clean install -Duser.home=/var/maven -Duser.name=jenkins'
}
}
@@ -44,12 +50,10 @@ node(label: 'ubuntu') {
// Conditional stage to deploy artifacts, when not building a PR
if (env.CHANGE_ID == null) {
stage('Deploy artifacts') {
- environmentDockerImage.inside('-i --name brooklyn-${DOCKER_TAG} --mount type=bind,source="${HOME}/.m2/settings.xml",target=/var/maven/.m2/settings.xml,readonly -v ${WORKSPACE}:/usr/build -w /usr/build') {
+ environmentDockerImage.inside('-i --name brooklyn-${DOCKER_TAG} -v ${WORKSPACE}/.m2:/var/maven/.m2 --mount type=bind,source="${HOME}/.m2/settings.xml",target=/var/maven/.m2/settings.xml,readonly -v ${WORKSPACE}:/usr/build -w /usr/build') {
sh 'mvn deploy -DskipTests -Duser.home=/var/maven -Duser.name=jenkins'
}
}
-
- // TODO: Publish docker image to https://hub.docker.com/r/apache/brooklyn/ ?
}
}
}