diff --git a/automation b/automation new file mode 100644 index 000000000..570c24e59 --- /dev/null +++ b/automation @@ -0,0 +1,44 @@ +pipeline{ + tools{ + jdk 'myjava' + maven 'mymaven' + } + agent any + stages{ + stage('checkout'){ + steps{ + git 'https://github.com/SobhaReddy/DevOpsClassCodes.git' + } + } + + } + stage('compile'){ + steps{ + sh 'mvn compile' + } + } + stage('codeReview'){ + steps{ + sh 'mvn pmd:pmd' + } + } + stage('unitTest'){ + steps{ + sh 'test' + } + } + stage('metricCheck'){ + steps{ + sh ' mvn cobertura:cobertura -Dcobertura.report.format=xml' + } + } + stage('package'){ + steps{ + sh ' mvn package' + } + } + + + + } +}