diff --git a/Jenkinsfile b/Jenkinsfile new file mode 100644 index 0000000000..266ca02f21 --- /dev/null +++ b/Jenkinsfile @@ -0,0 +1,35 @@ +//Declarative script + +pipeline{ + agent any + tools { + maven "maven3.8.4" + } + stages{ + stage('GitClone'){ + steps{ + sh"echo cloning the latest application version" + git "https://github.com/colinfuanjia/hello-world" + } + } + stage('TestBuild'){ + steps{ + sh"echo running UnitTesting" + sh "mvn package" + } + } + /* stage("Upload"){ + steps { + withCredentials(credentialsId: 'S3Credentials', accessKeyVariable: 'AKIAQHO2RT6EJCZHZTHN', secretKeyVariable: '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') + */ + stage("Upload"){ + steps{ + withAWS(region:"${region}", credentials:"${aws_credential}){ + s3Upload(file:"${TAG_NAME}", bucket:"${bucket}", path:"${TAG_NAME}/") + } + } + } + } + } + +