diff --git a/Jenkinsfile b/Jenkinsfile deleted file mode 100644 index c549f81c..00000000 --- a/Jenkinsfile +++ /dev/null @@ -1,50 +0,0 @@ -pipeline { - agent any - stages { - stage ('Build Servlet Project') { - steps { - /*For windows machine */ - bat 'mvn clean package' - - /*For Mac & Linux machine */ - // sh 'mvn clean package' - } - - post{ - success{ - echo 'Now Archiving ....' - - archiveArtifacts artifacts : '**/*.war' - } - } - } - - stage ('Deploy Build in Staging Area'){ - steps{ - - build job : 'Deploy-StagingArea-Piple' - - } - } - - stage ('Deploy to Production'){ - steps{ - timeout (time: 5, unit:'DAYS'){ - input message: 'Approve PRODUCTION Deployment?' - } - - build job : 'Deploy-Production-Pipeline' - } - - post{ - success{ - echo 'Deployment on PRODUCTION is Successful' - } - - failure{ - echo 'Deployement Failure on PRODUCTION' - } - } - } - } -} diff --git a/Packer_servlet_jenkinsfile/Jenkinsfile b/Packer_servlet_jenkinsfile/Jenkinsfile new file mode 100644 index 00000000..bd965e96 --- /dev/null +++ b/Packer_servlet_jenkinsfile/Jenkinsfile @@ -0,0 +1,24 @@ +pipeline { + agent any + tools { + maven 'localMaven' + } + stages { + stage ('Build Servlet Project') { + steps { + sh 'mvn clean package' + } + + post { + success{ + echo 'Now Archiving ....' + + archiveArtifacts artifacts : '**/*.war' + } + } + } + + } + +} + diff --git a/Sample1_Jenkinsfile b/Sample1_Jenkinsfile deleted file mode 100644 index 34029ddb..00000000 --- a/Sample1_Jenkinsfile +++ /dev/null @@ -1,37 +0,0 @@ -pipeline{ - - /* A decalarative pipeline*/ - agent any - - stages{ - - agent ABC - - stage('Build'){ - - steps{ - - - } - } - - agent XYZ - - stage('Deploy to Staging'){ - /*Agent selection could go here as well*/ - steps{ - - - } - - } - } -} - -wget -q -O - http://pkg.jenkins-ci.org/debian/jenkins-ci.org.key | apt-key add - - -echo deb http://pkg.jenkins-ci.org/debian binary/ > /etc/apt/sources.list.d/jenkins.list - -apt-get update - -apt-get install jenkins \ No newline at end of file diff --git a/Sample_Jenkinsfile b/Sample_Jenkinsfile deleted file mode 100644 index 8b085ed6..00000000 --- a/Sample_Jenkinsfile +++ /dev/null @@ -1,22 +0,0 @@ -pipeline { - agent any - stages { - stage ('Initialize') { - steps { - echo "Initializing the Code File" - } - } - - stage ('Build') { - steps { - echo 'Hello World' - } - } - - stage ('Deploy') { - steps { - echo 'Deployed an Artifact' - } - } - } -} diff --git a/src/main/webapp/index.jsp b/src/main/webapp/index.jsp index 36de42ba..daecf34c 100644 --- a/src/main/webapp/index.jsp +++ b/src/main/webapp/index.jsp @@ -2,9 +2,9 @@

Hello World!

-

WelCome to Jenkins! We are working on Code Pipeline version 2

- -

This is change is to verify the Stage vs Production

> +

WelCome to Jenkins!

+

Hello mayank varsheny

> +

HOW ARE YOU