This is an automated email from the ASF dual-hosted git repository. lukaszlenart pushed a commit to branch docker-build in repository https://gitbox.apache.org/repos/asf/struts.git
commit 5918617826eb034a41720cec9e6c66c072d72067 Author: Lukasz Lenart <lukaszlen...@apache.org> AuthorDate: Tue Aug 27 08:55:51 2019 +0200 Defines a simple Docker build --- Jenkinsfile | 21 +++++++++++++++++---- 1 file changed, 17 insertions(+), 4 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 7686d89..e79f0da 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -1,8 +1,6 @@ #!groovy pipeline { - agent { - label 'ubuntu' - } + agent none options { buildDiscarder logRotator(daysToKeepStr: '14', numToKeepStr: '10') timeout(80) @@ -20,10 +18,25 @@ pipeline { } stages { stage('Build') { + agent { + label 'ubuntu' + } steps { - sh 'mvn --version' + sh 'mvn -v' sh 'mvn clean source:jar javadoc:jar install deploy -DskipWiki -Dhttps.protocols=TLSv1,TLSv1.1,TLSv1.2' } } + stage('Docker build') { + agent { + docker { + image 'maven:3-alpine' + args '-v $HOME/.m2:/root/.m2' + } + } + steps { + sh 'mvn -v' + sh 'mvn clean test -DskipWiki' + } + } } }