From ca705dc6a93ed6ac7c62fa1d3425f70fa4a345d7 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Tue, 22 Mar 2022 08:54:57 +0530 Subject: [PATCH 01/59] edit --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 2d4e291f5..954a328fc 100644 --- a/README.md +++ b/README.md @@ -2,3 +2,4 @@ Hello World! (WAR-style) =============== This is the simplest possible Java webapp for testing servlet container deployments. It should work on any container and requires no other dependencies or configuration. +Check in for new edit From 0c73780c8681bca5c9ec62a4855fd20190650cc1 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Tue, 22 Mar 2022 08:57:53 +0530 Subject: [PATCH 02/59] second edit --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 954a328fc..68649489a 100644 --- a/README.md +++ b/README.md @@ -3,3 +3,4 @@ Hello World! (WAR-style) This is the simplest possible Java webapp for testing servlet container deployments. It should work on any container and requires no other dependencies or configuration. Check in for new edit +second edit should happen automatically From 97497b0f75f048d56923ad4fb273d46eaedad6f9 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Tue, 22 Mar 2022 09:00:24 +0530 Subject: [PATCH 03/59] third edit --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 68649489a..1ba70e5da 100644 --- a/README.md +++ b/README.md @@ -4,3 +4,4 @@ Hello World! (WAR-style) This is the simplest possible Java webapp for testing servlet container deployments. It should work on any container and requires no other dependencies or configuration. Check in for new edit second edit should happen automatically +now it should happen From 4edb48a9392847d65db04729765428c7a0d19642 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Tue, 22 Mar 2022 09:02:24 +0530 Subject: [PATCH 04/59] fourth --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 1ba70e5da..e1b01203b 100644 --- a/README.md +++ b/README.md @@ -5,3 +5,4 @@ This is the simplest possible Java webapp for testing servlet container deployme Check in for new edit second edit should happen automatically now it should happen +fourth edit From c925ceb868f94ebaa4c5dce15c15903c3ce1214b Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Tue, 22 Mar 2022 12:46:29 +0530 Subject: [PATCH 05/59] edit 5 --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index e1b01203b..27c3637c9 100644 --- a/README.md +++ b/README.md @@ -6,3 +6,4 @@ Check in for new edit second edit should happen automatically now it should happen fourth edit +edit 5 From 43ea7f5adbf8a26ebee94d43daf294cbd4f62b50 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Tue, 22 Mar 2022 12:48:42 +0530 Subject: [PATCH 06/59] edit 6 --- README.md | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/README.md b/README.md index 27c3637c9..496127f12 100644 --- a/README.md +++ b/README.md @@ -3,7 +3,4 @@ Hello World! (WAR-style) This is the simplest possible Java webapp for testing servlet container deployments. It should work on any container and requires no other dependencies or configuration. Check in for new edit -second edit should happen automatically -now it should happen -fourth edit -edit 5 +second edit is happening From 0fb853f5bd98e7facee8f9d6fc5287dde475101d Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Wed, 23 Mar 2022 08:36:30 +0530 Subject: [PATCH 07/59] Create Jenkins --- Jenkins | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 Jenkins diff --git a/Jenkins b/Jenkins new file mode 100644 index 000000000..3f1a39fea --- /dev/null +++ b/Jenkins @@ -0,0 +1,16 @@ +pipeline { + agent { label 'slave2' } + stages { + stage('checkout') { + steps { + sh "git clone https://github.com/Lohras/hello-world-war.git" + } + } +stage('build') { + steps { + sh "mvn clean package" + } + } + + } +} From baf5ffdce4b13bf09940a090fa2c9575c78aee11 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Wed, 23 Mar 2022 08:39:46 +0530 Subject: [PATCH 08/59] Rename Jenkins to Jenkinsfile --- Jenkins => Jenkinsfile | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename Jenkins => Jenkinsfile (100%) diff --git a/Jenkins b/Jenkinsfile similarity index 100% rename from Jenkins rename to Jenkinsfile From 00d0e270c3f408ede53b98f15b61cbcc52da6dd4 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Wed, 23 Mar 2022 08:44:43 +0530 Subject: [PATCH 09/59] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 3f1a39fea..de7420f6c 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -1,5 +1,5 @@ pipeline { - agent { label 'slave2' } + agent { label 'my_slave1' } stages { stage('checkout') { steps { From 5bffd78eebb3cedaf40472b72ac67cda64f8a820 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Wed, 23 Mar 2022 08:53:04 +0530 Subject: [PATCH 10/59] Update Jenkinsfile --- Jenkinsfile | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index de7420f6c..42ef15db5 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -1,16 +1,20 @@ pipeline { - agent { label 'my_slave1' } + agent { label 'slave2' } stages { stage('checkout') { steps { + sh " rm -rf /home/slave2/workspace/job_pip" sh "git clone https://github.com/Lohras/hello-world-war.git" } } stage('build') { steps { + sh "apt-get update" + sh "apt install default-jre" sh "mvn clean package" } } - - } -} +stage('deploy') { + steps { + sh "cp /home/slave2/workspace/job_pip/" + From cda91c05834cc649b8c0e3fe0f71f925591a3e60 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Wed, 23 Mar 2022 08:54:36 +0530 Subject: [PATCH 11/59] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 42ef15db5..9c4725f89 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -3,7 +3,7 @@ pipeline { stages { stage('checkout') { steps { - sh " rm -rf /home/slave2/workspace/job_pip" + sh " git pull " sh "git clone https://github.com/Lohras/hello-world-war.git" } } From 504db150e6b55465a3ac4b7a40fcf0d5b7e2cb34 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Wed, 23 Mar 2022 08:56:46 +0530 Subject: [PATCH 12/59] Update Jenkinsfile --- Jenkinsfile | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 9c4725f89..de82b679d 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -3,8 +3,7 @@ pipeline { stages { stage('checkout') { steps { - sh " git pull " - sh "git clone https://github.com/Lohras/hello-world-war.git" + sh "git pull https://github.com/Lohras/hello-world-war.git" } } stage('build') { @@ -17,4 +16,7 @@ stage('build') { stage('deploy') { steps { sh "cp /home/slave2/workspace/job_pip/" - + } +} + } +} From 650f5da60ddd2ba602319cd2d24f27a0907277dd Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Wed, 23 Mar 2022 09:00:03 +0530 Subject: [PATCH 13/59] Update Jenkinsfile --- Jenkinsfile | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index de82b679d..a812e0de3 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -7,9 +7,7 @@ pipeline { } } stage('build') { - steps { - sh "apt-get update" - sh "apt install default-jre" + steps { sh "mvn clean package" } } From 0b54d7e147a1f6a5d46a9de2d7c026ae007feca6 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Wed, 23 Mar 2022 09:01:03 +0530 Subject: [PATCH 14/59] Update Jenkinsfile --- Jenkinsfile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index a812e0de3..9f6eb26b1 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -7,7 +7,8 @@ pipeline { } } stage('build') { - steps { + steps { + sh " apt install maven -y " sh "mvn clean package" } } From 51fe17ff59f4262e3a37de16c21ff43b2172c120 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Wed, 23 Mar 2022 09:06:32 +0530 Subject: [PATCH 15/59] Update Jenkinsfile --- Jenkinsfile | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 9f6eb26b1..de7420f6c 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -1,21 +1,16 @@ pipeline { - agent { label 'slave2' } + agent { label 'my_slave1' } stages { stage('checkout') { steps { - sh "git pull https://github.com/Lohras/hello-world-war.git" + sh "git clone https://github.com/Lohras/hello-world-war.git" } } stage('build') { steps { - sh " apt install maven -y " sh "mvn clean package" } } -stage('deploy') { - steps { - sh "cp /home/slave2/workspace/job_pip/" - } -} + } } From 02c42178badbe31f53c197fa8d508ea243ef8e0b Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Wed, 23 Mar 2022 09:07:57 +0530 Subject: [PATCH 16/59] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index de7420f6c..906b324d5 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -3,7 +3,7 @@ pipeline { stages { stage('checkout') { steps { - sh "git clone https://github.com/Lohras/hello-world-war.git" + sh "git pull https://github.com/Lohras/hello-world-war.git" } } stage('build') { From 3d2e873bfe32272e122ae6c5a38b08d3fcaef42a Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Wed, 23 Mar 2022 09:11:18 +0530 Subject: [PATCH 17/59] jenkins --- Jenkinsfile | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 906b324d5..f0649d410 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -11,6 +11,10 @@ stage('build') { sh "mvn clean package" } } - + Stage('deploy') { + steps { + sh " sudo cp /home/jenkins/workspace/Pipejob1/target/hello-world-war-1.0.0.war /opt/apache-tomcat-9.0.60/webapps" + } + } } } From d8978ff328dec1df470fbe582f0aaf525394d77c Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Wed, 23 Mar 2022 09:12:58 +0530 Subject: [PATCH 18/59] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index f0649d410..cc3d17b47 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -11,7 +11,7 @@ stage('build') { sh "mvn clean package" } } - Stage('deploy') { +Stage('deploy') { steps { sh " sudo cp /home/jenkins/workspace/Pipejob1/target/hello-world-war-1.0.0.war /opt/apache-tomcat-9.0.60/webapps" } From 2b347c6a4c0095b31bcdf30d44fe3676e4f00862 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Wed, 23 Mar 2022 09:13:13 +0530 Subject: [PATCH 19/59] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index cc3d17b47..73845924f 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -11,7 +11,7 @@ stage('build') { sh "mvn clean package" } } -Stage('deploy') { +stage('deploy') { steps { sh " sudo cp /home/jenkins/workspace/Pipejob1/target/hello-world-war-1.0.0.war /opt/apache-tomcat-9.0.60/webapps" } From c8d2811f26c877756e84c3ad477bc63d0c3b269d Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Wed, 23 Mar 2022 09:15:38 +0530 Subject: [PATCH 20/59] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 73845924f..dedb8bc75 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -13,7 +13,7 @@ stage('build') { } stage('deploy') { steps { - sh " sudo cp /home/jenkins/workspace/Pipejob1/target/hello-world-war-1.0.0.war /opt/apache-tomcat-9.0.60/webapps" + sh " cp /home/jenkins/workspace/Pipejob1/target/hello-world-war-1.0.0.war /opt/apache-tomcat-9.0.60/webapps" } } } From d49640ccf07a5e7ae5c2b80f3612fc3e36ee0261 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Wed, 23 Mar 2022 09:26:53 +0530 Subject: [PATCH 21/59] Update Jenkinsfile --- Jenkinsfile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index dedb8bc75..e44f28253 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -13,7 +13,8 @@ stage('build') { } stage('deploy') { steps { - sh " cp /home/jenkins/workspace/Pipejob1/target/hello-world-war-1.0.0.war /opt/apache-tomcat-9.0.60/webapps" + sh " cd /opt " + sh " cp /home/jenkins/workspace/Pipejob1/target/hello-world-war-1.0.0 /opt/apache-tomcat-9.0.60/webapps" } } } From cc4248a2faa8165190a5f379148cd07b16cf2fda Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Wed, 23 Mar 2022 09:27:53 +0530 Subject: [PATCH 22/59] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index e44f28253..d9a7ee707 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -14,7 +14,7 @@ stage('build') { stage('deploy') { steps { sh " cd /opt " - sh " cp /home/jenkins/workspace/Pipejob1/target/hello-world-war-1.0.0 /opt/apache-tomcat-9.0.60/webapps" + sh " cp /home/jenkins/workspace/Pipejob1/target/hello-world-war-1.0.0 /opt" } } } From f276e45a6413023fcce8cc331c672d831ded0bf4 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Wed, 23 Mar 2022 09:28:37 +0530 Subject: [PATCH 23/59] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index d9a7ee707..46870c5e0 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -14,7 +14,7 @@ stage('build') { stage('deploy') { steps { sh " cd /opt " - sh " cp /home/jenkins/workspace/Pipejob1/target/hello-world-war-1.0.0 /opt" + sh " cp -r /home/jenkins/workspace/Pipejob1/target/hello-world-war-1.0.0 /opt" } } } From 0436b028d44e6afe02563a2f468ea3ffd2a29e10 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Wed, 23 Mar 2022 09:29:31 +0530 Subject: [PATCH 24/59] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 46870c5e0..cafb968e5 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -14,7 +14,7 @@ stage('build') { stage('deploy') { steps { sh " cd /opt " - sh " cp -r /home/jenkins/workspace/Pipejob1/target/hello-world-war-1.0.0 /opt" + sh " cp -r /home/jenkins/workspace/Pipejob1/target/hello-world-war-1.0.0.war /opt" } } } From 783a87aafb9e688cded877162cb6346e920fce42 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Wed, 23 Mar 2022 10:36:04 +0530 Subject: [PATCH 25/59] Update Jenkinsfile --- Jenkinsfile | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index cafb968e5..dedb8bc75 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -13,8 +13,7 @@ stage('build') { } stage('deploy') { steps { - sh " cd /opt " - sh " cp -r /home/jenkins/workspace/Pipejob1/target/hello-world-war-1.0.0.war /opt" + sh " cp /home/jenkins/workspace/Pipejob1/target/hello-world-war-1.0.0.war /opt/apache-tomcat-9.0.60/webapps" } } } From d105389ba77cc63267fc6d1b5522d30357c3cc9e Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Thu, 24 Mar 2022 07:16:48 +0530 Subject: [PATCH 26/59] Update README.md --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 496127f12..18b97a976 100644 --- a/README.md +++ b/README.md @@ -4,3 +4,4 @@ Hello World! (WAR-style) This is the simplest possible Java webapp for testing servlet container deployments. It should work on any container and requires no other dependencies or configuration. Check in for new edit second edit is happening +test multibrnch From 6ca68f3a0b8effb14f746acd128858efcea1bcf8 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Thu, 24 Mar 2022 07:53:24 +0530 Subject: [PATCH 27/59] Update README.md --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 496127f12..03e849f76 100644 --- a/README.md +++ b/README.md @@ -4,3 +4,4 @@ Hello World! (WAR-style) This is the simplest possible Java webapp for testing servlet container deployments. It should work on any container and requires no other dependencies or configuration. Check in for new edit second edit is happening +editing to make sure the changes for reviewing From 5c5bc77f1d504ea6ba41387180ff435e6a2a93c1 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Fri, 25 Mar 2022 00:48:13 +0530 Subject: [PATCH 28/59] version1.0.1 --- pom.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pom.xml b/pom.xml index 85f2e2e2a..081d07489 100644 --- a/pom.xml +++ b/pom.xml @@ -3,7 +3,7 @@ 4.0.0 com.efsavage hello-world-war - 1.0.0 + 1.0.1 war Hello World Web Application Repository Simplest possible Java Webapp @@ -26,4 +26,4 @@ - \ No newline at end of file + From a6dfdfadc0ee9af446b435e93013c696a97e54ae Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Sun, 10 Apr 2022 13:16:22 +0530 Subject: [PATCH 29/59] Create Dockerfile --- Dockerfile | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 Dockerfile diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 000000000..1326930a8 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,2 @@ +FROM tomcat:8 +COPY target/*.war /usr/local/tomcat/webapps From 8778456f7727886f277c8c08b84f27af7430ddfb Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Sun, 10 Apr 2022 16:34:42 +0530 Subject: [PATCH 30/59] Update Dockerfile --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 1326930a8..7a55e7eb1 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,2 +1,2 @@ -FROM tomcat:8 +FROM tomcat:9.0 COPY target/*.war /usr/local/tomcat/webapps From b5424ece814d366b0143a2d94aa541e81662b8b1 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Sun, 10 Apr 2022 16:37:00 +0530 Subject: [PATCH 31/59] Update Jenkinsfile --- Jenkinsfile | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index dedb8bc75..2001ff159 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -1,5 +1,5 @@ pipeline { - agent { label 'my_slave1' } + agent { label 'last1' } stages { stage('checkout') { steps { @@ -11,10 +11,5 @@ stage('build') { sh "mvn clean package" } } -stage('deploy') { - steps { - sh " cp /home/jenkins/workspace/Pipejob1/target/hello-world-war-1.0.0.war /opt/apache-tomcat-9.0.60/webapps" - } - } } } From d305cbc6c20ac9a7079cd1475ef77c1f40b38011 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Sun, 10 Apr 2022 16:43:27 +0530 Subject: [PATCH 32/59] Update Jenkinsfile --- Jenkinsfile | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 2001ff159..211352033 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -6,10 +6,15 @@ pipeline { sh "git pull https://github.com/Lohras/hello-world-war.git" } } -stage('build') { - steps { + stage('build') { + steps { sh "mvn clean package" } } + stage('build image') { + steps { + sh 'docker build -t lohith2022.jfrog.io/jfrog-local/dock:1.0' + } + } } } From 02a3495db8d450f6738487e46542647bb7623549 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Sun, 10 Apr 2022 16:49:40 +0530 Subject: [PATCH 33/59] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 211352033..360c06769 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -13,7 +13,7 @@ pipeline { } stage('build image') { steps { - sh 'docker build -t lohith2022.jfrog.io/jfrog-local/dock:1.0' + sh 'docker build -t lohith2022.jfrog.io/jfrog-local/dock:1.0 .' } } } From dfc0fd7fba84f267d0b023ec37dda4f137504189 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Sun, 10 Apr 2022 17:32:21 +0530 Subject: [PATCH 34/59] Update Jenkinsfile --- Jenkinsfile | 50 ++++++++++++++++++++++++++++++++------------------ 1 file changed, 32 insertions(+), 18 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 360c06769..5183b8d33 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -1,20 +1,34 @@ -pipeline { - agent { label 'last1' } - stages { - stage('checkout') { - steps { - sh "git pull https://github.com/Lohras/hello-world-war.git" +pipeline{ + agent { label 'last1' } + stages{ + stage('check out'){ + steps{ + sh "rm -rf hello-world-war" + sh "git clone " + } + } + stage('build'){ + steps{ + sh "pwd" + sh "ls" + sh "cd hello-world-war" + sh "docker build -t lohith2022.jfrog.io/docker:1.0 ." + } + } + stage('publish'){ + steps{ + sh "docker login -u lohith2022 -p Lohith@1994" + sh "docker push lohith2022.jfrog.io/docker:1.0" + } } - } - stage('build') { - steps { - sh "mvn clean package" + stage('deploy'){ + agent { label 'slave2' } + steps{ + sh "docker login -u lohith2022 -p Lohith@1994" + sh "docker pull lohith2022.jfrog.io/docker:1.0" + //sh "docker rm -f \$(docker ps -a -q --filter ancestor=sandy1791994/docwarimage:1.0)" + sh "docker run -d -p 8050:8080 --name docker1 lohith2022.jfrog.io/docker:1.0" + } } - } - stage('build image') { - steps { - sh 'docker build -t lohith2022.jfrog.io/jfrog-local/dock:1.0 .' - } - } - } -} + } + } From b74f461cc3da17f4a1caa8436d3663a6b20ef2e5 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Sun, 10 Apr 2022 17:32:59 +0530 Subject: [PATCH 35/59] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 5183b8d33..9bf7f9d01 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -4,7 +4,7 @@ pipeline{ stage('check out'){ steps{ sh "rm -rf hello-world-war" - sh "git clone " + sh "git clone https://github.com/Lohras/hello-world-war.git" } } stage('build'){ From 085f52c75389f015fa40fb48bdcdb644992629f3 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Sun, 10 Apr 2022 17:45:19 +0530 Subject: [PATCH 36/59] Update Dockerfile --- Dockerfile | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index 7a55e7eb1..d0163c040 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,2 +1,9 @@ -FROM tomcat:9.0 -COPY target/*.war /usr/local/tomcat/webapps +FROM maven:3.8.2-openjdk-8 as mavenbuilder +ARG TEST=/var/lib/ +WORKDIR ${TEST} +COPY . . +RUN mvn clean package + +FROM tomcat:jre8-temurin-focal +ARG TEST=/var/lib +COPY --from=mavenbuilder ${TEST}/target/hello-world-war-1.0.0.war /usr/local/tomcat/webapps From 10e5317cceb83a6cadd037bca8f948a2bcdc9c28 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Sun, 10 Apr 2022 17:48:13 +0530 Subject: [PATCH 37/59] Update Jenkinsfile --- Jenkinsfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 9bf7f9d01..c22daf5f3 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -17,14 +17,14 @@ pipeline{ } stage('publish'){ steps{ - sh "docker login -u lohith2022 -p Lohith@1994" + sh "docker login -u lohith2022.jfrog.io -p Lohith@1994" sh "docker push lohith2022.jfrog.io/docker:1.0" } } stage('deploy'){ agent { label 'slave2' } steps{ - sh "docker login -u lohith2022 -p Lohith@1994" + sh "docker login -u lohith2022.jfrog.io -p Lohith@1994" sh "docker pull lohith2022.jfrog.io/docker:1.0" //sh "docker rm -f \$(docker ps -a -q --filter ancestor=sandy1791994/docwarimage:1.0)" sh "docker run -d -p 8050:8080 --name docker1 lohith2022.jfrog.io/docker:1.0" From 9a308a8bf60e14bc2928e9d37f49fd6880b99ddc Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Sun, 10 Apr 2022 18:00:36 +0530 Subject: [PATCH 38/59] Update Dockerfile --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index d0163c040..2235f9c6e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -6,4 +6,4 @@ RUN mvn clean package FROM tomcat:jre8-temurin-focal ARG TEST=/var/lib -COPY --from=mavenbuilder ${TEST}/target/hello-world-war-1.0.0.war /usr/local/tomcat/webapps +COPY --from=mavenbuilder ${TEST}/target/hello-world-war-1.0.1.war /usr/local/tomcat/webapps From 5ad4a320938a8d3c1afcc0c777b0f96282460013 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Sun, 10 Apr 2022 18:17:29 +0530 Subject: [PATCH 39/59] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index c22daf5f3..69fe04159 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -17,7 +17,7 @@ pipeline{ } stage('publish'){ steps{ - sh "docker login -u lohith2022.jfrog.io -p Lohith@1994" + sh "docker login -u lohith2022.jfrog.io --p Lohith@1994" sh "docker push lohith2022.jfrog.io/docker:1.0" } } From 31514f076603cde9bb9ea1831359f8aa8d207bc4 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Sun, 10 Apr 2022 18:40:15 +0530 Subject: [PATCH 40/59] Update Jenkinsfile --- Jenkinsfile | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 69fe04159..05348b90f 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -12,22 +12,22 @@ pipeline{ sh "pwd" sh "ls" sh "cd hello-world-war" - sh "docker build -t lohith2022.jfrog.io/docker:1.0 ." + sh "docker build -t lohith1994/dockerrepo/dock:1.0 ." } } stage('publish'){ steps{ - sh "docker login -u lohith2022.jfrog.io --p Lohith@1994" - sh "docker push lohith2022.jfrog.io/docker:1.0" + sh "docker login -u lohith1994 -p Lohith@1994" + sh "docker push lohith1994/dockerrepo/dock:1.0" } } stage('deploy'){ agent { label 'slave2' } steps{ - sh "docker login -u lohith2022.jfrog.io -p Lohith@1994" - sh "docker pull lohith2022.jfrog.io/docker:1.0" - //sh "docker rm -f \$(docker ps -a -q --filter ancestor=sandy1791994/docwarimage:1.0)" - sh "docker run -d -p 8050:8080 --name docker1 lohith2022.jfrog.io/docker:1.0" + //sh "docker login -u lohith1994 -p Lohith@1994" + sh "docker pull lohith1994/dockerrepo/dock:1.0" + //sh "docker rm -f docker1" + sh "docker run -d -p 8040:8080 --name docker1 lohith1994/dockerrepo/dock:1.0" } } } From 292ae0560722b81c002220712146635066ff43ae Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Sun, 10 Apr 2022 18:42:30 +0530 Subject: [PATCH 41/59] Update Jenkinsfile --- Jenkinsfile | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 05348b90f..169342590 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -12,22 +12,22 @@ pipeline{ sh "pwd" sh "ls" sh "cd hello-world-war" - sh "docker build -t lohith1994/dockerrepo/dock:1.0 ." + sh "docker build -t lohith1994/dockerrepo:1.0 ." } } stage('publish'){ steps{ sh "docker login -u lohith1994 -p Lohith@1994" - sh "docker push lohith1994/dockerrepo/dock:1.0" + sh "docker push lohith1994/dockerrepo:1.0" } } stage('deploy'){ agent { label 'slave2' } steps{ //sh "docker login -u lohith1994 -p Lohith@1994" - sh "docker pull lohith1994/dockerrepo/dock:1.0" + sh "docker pull lohith1994/dockerrepo:1.0" //sh "docker rm -f docker1" - sh "docker run -d -p 8040:8080 --name docker1 lohith1994/dockerrepo/dock:1.0" + sh "docker run -d -p 8040:8080 --name docker1 lohith1994/dockerrepo:1.0" } } } From 868dd25fa2270f85229ccd1b6d5890af5f2e266f Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Sun, 10 Apr 2022 18:46:25 +0530 Subject: [PATCH 42/59] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 169342590..61893c9f5 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -26,7 +26,7 @@ pipeline{ steps{ //sh "docker login -u lohith1994 -p Lohith@1994" sh "docker pull lohith1994/dockerrepo:1.0" - //sh "docker rm -f docker1" + sh "docker rm -f docker1" sh "docker run -d -p 8040:8080 --name docker1 lohith1994/dockerrepo:1.0" } } From 1da6c62484a74bf3460dc9dd7b4947906d332111 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Sun, 10 Apr 2022 18:47:37 +0530 Subject: [PATCH 43/59] Update Jenkinsfile --- Jenkinsfile | 1 + 1 file changed, 1 insertion(+) diff --git a/Jenkinsfile b/Jenkinsfile index 61893c9f5..0cd1f3019 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -25,6 +25,7 @@ pipeline{ agent { label 'slave2' } steps{ //sh "docker login -u lohith1994 -p Lohith@1994" + //not necessary as it'll refer to docker hub is (default) & repo is public sh "docker pull lohith1994/dockerrepo:1.0" sh "docker rm -f docker1" sh "docker run -d -p 8040:8080 --name docker1 lohith1994/dockerrepo:1.0" From a6306555875406284974be98fe9f7d1db042ce5a Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Sun, 10 Apr 2022 18:49:23 +0530 Subject: [PATCH 44/59] Update index.jsp --- src/main/webapp/index.jsp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/main/webapp/index.jsp b/src/main/webapp/index.jsp index ead0e510f..67073c35a 100644 --- a/src/main/webapp/index.jsp +++ b/src/main/webapp/index.jsp @@ -1,13 +1,13 @@ -Hello World! +Hello DevOps World! -

Hello World!

+

Hello DevOps World!

It is now <%= new java.util.Date() %>

You are coming from <%= request.getRemoteAddr() %>

- \ No newline at end of file + From a69392f5bdf1c605c8d28e1b70b16ded352e1edb Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Mon, 11 Apr 2022 08:24:30 +0530 Subject: [PATCH 45/59] Updating the build number --- Jenkinsfile | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 0cd1f3019..6adac3479 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -12,13 +12,14 @@ pipeline{ sh "pwd" sh "ls" sh "cd hello-world-war" - sh "docker build -t lohith1994/dockerrepo:1.0 ." + //${BUILD_NUMBER} is used to get the build numbers for every successful builds. + sh "docker build -t lohith1994/dockerrepo:${BUILD_NUMBER} ." } } stage('publish'){ steps{ sh "docker login -u lohith1994 -p Lohith@1994" - sh "docker push lohith1994/dockerrepo:1.0" + sh "docker push lohith1994/dockerrepo:${BUILD_NUMBER}" } } stage('deploy'){ @@ -26,9 +27,9 @@ pipeline{ steps{ //sh "docker login -u lohith1994 -p Lohith@1994" //not necessary as it'll refer to docker hub is (default) & repo is public - sh "docker pull lohith1994/dockerrepo:1.0" + sh "docker pull lohith1994/dockerrepo:${BUILD_NUMBER}" sh "docker rm -f docker1" - sh "docker run -d -p 8040:8080 --name docker1 lohith1994/dockerrepo:1.0" + sh "docker run -d -p 8040:8080 --name docker1 lohith1994/dockerrepo:${BUILD_NUMBER}" } } } From a5fbf3e8bd42af8b2fe70d2d8d864b78ebae5900 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Mon, 11 Apr 2022 08:36:12 +0530 Subject: [PATCH 46/59] Revert "Updating the build number" This reverts commit a69392f5bdf1c605c8d28e1b70b16ded352e1edb. --- Jenkinsfile | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 6adac3479..0cd1f3019 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -12,14 +12,13 @@ pipeline{ sh "pwd" sh "ls" sh "cd hello-world-war" - //${BUILD_NUMBER} is used to get the build numbers for every successful builds. - sh "docker build -t lohith1994/dockerrepo:${BUILD_NUMBER} ." + sh "docker build -t lohith1994/dockerrepo:1.0 ." } } stage('publish'){ steps{ sh "docker login -u lohith1994 -p Lohith@1994" - sh "docker push lohith1994/dockerrepo:${BUILD_NUMBER}" + sh "docker push lohith1994/dockerrepo:1.0" } } stage('deploy'){ @@ -27,9 +26,9 @@ pipeline{ steps{ //sh "docker login -u lohith1994 -p Lohith@1994" //not necessary as it'll refer to docker hub is (default) & repo is public - sh "docker pull lohith1994/dockerrepo:${BUILD_NUMBER}" + sh "docker pull lohith1994/dockerrepo:1.0" sh "docker rm -f docker1" - sh "docker run -d -p 8040:8080 --name docker1 lohith1994/dockerrepo:${BUILD_NUMBER}" + sh "docker run -d -p 8040:8080 --name docker1 lohith1994/dockerrepo:1.0" } } } From 90a8bc155cffec3fcbb07988232dd25bb5d187cd Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Mon, 11 Apr 2022 09:13:20 +0530 Subject: [PATCH 47/59] Update Jenkinsfile --- Jenkinsfile | 1 + 1 file changed, 1 insertion(+) diff --git a/Jenkinsfile b/Jenkinsfile index 0cd1f3019..1e16dffb8 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -2,6 +2,7 @@ pipeline{ agent { label 'last1' } stages{ stage('check out'){ + //used to checkout from git steps{ sh "rm -rf hello-world-war" sh "git clone https://github.com/Lohras/hello-world-war.git" From fcb23854e10e9073e22641b67d2fee4591b6009c Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Mon, 11 Apr 2022 17:29:47 +0530 Subject: [PATCH 48/59] Update Jenkinsfile --- Jenkinsfile | 46 +++++++++++----------------------------------- 1 file changed, 11 insertions(+), 35 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 1e16dffb8..d370161e9 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -1,36 +1,12 @@ -pipeline{ - agent { label 'last1' } - stages{ - stage('check out'){ - //used to checkout from git - steps{ - sh "rm -rf hello-world-war" - sh "git clone https://github.com/Lohras/hello-world-war.git" - } - } - stage('build'){ - steps{ - sh "pwd" - sh "ls" - sh "cd hello-world-war" - sh "docker build -t lohith1994/dockerrepo:1.0 ." - } - } - stage('publish'){ - steps{ - sh "docker login -u lohith1994 -p Lohith@1994" - sh "docker push lohith1994/dockerrepo:1.0" - } +pipeline { + agent { + docker { image 'node:16.13.1-alpine' } + } + stages { + stage('Test') { + steps { + sh 'node --version' } - stage('deploy'){ - agent { label 'slave2' } - steps{ - //sh "docker login -u lohith1994 -p Lohith@1994" - //not necessary as it'll refer to docker hub is (default) & repo is public - sh "docker pull lohith1994/dockerrepo:1.0" - sh "docker rm -f docker1" - sh "docker run -d -p 8040:8080 --name docker1 lohith1994/dockerrepo:1.0" - } - } - } - } + } + } +} From 5826e8efbae1e7d13aaba42eed59d11a94bd10c9 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Mon, 11 Apr 2022 17:31:28 +0530 Subject: [PATCH 49/59] Update Dockerfile --- Dockerfile | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/Dockerfile b/Dockerfile index 2235f9c6e..ad2e2d75d 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,9 +1,7 @@ -FROM maven:3.8.2-openjdk-8 as mavenbuilder -ARG TEST=/var/lib/ -WORKDIR ${TEST} -COPY . . -RUN mvn clean package +FROM ubuntu:20.04 as slave +RUN apt-get update +RUN apt install maven -FROM tomcat:jre8-temurin-focal -ARG TEST=/var/lib -COPY --from=mavenbuilder ${TEST}/target/hello-world-war-1.0.1.war /usr/local/tomcat/webapps +#FROM tomcat:jre8-temurin-focal +#ARG TEST=/var/lib +#COPY --from=mavenbuilder ${TEST}/target/hello-world-war-1.0.1.war /usr/local/tomcat/webapps From d9e1eb7e774aa513beb94817ec3ed431069dc7d5 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Mon, 11 Apr 2022 17:36:53 +0530 Subject: [PATCH 50/59] Update Jenkinsfile --- Jenkinsfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index d370161e9..d8aa43327 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -1,11 +1,11 @@ pipeline { agent { - docker { image 'node:16.13.1-alpine' } + docker { image 'build:1.0' } } stages { stage('Test') { steps { - sh 'node --version' + sh 'mkdir -p SLAVE' } } } From 8630ebd2f17b0121d3dba00e1d62876ea564468a Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Mon, 11 Apr 2022 17:46:26 +0530 Subject: [PATCH 51/59] Update Jenkinsfile --- Jenkinsfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index d8aa43327..d370161e9 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -1,11 +1,11 @@ pipeline { agent { - docker { image 'build:1.0' } + docker { image 'node:16.13.1-alpine' } } stages { stage('Test') { steps { - sh 'mkdir -p SLAVE' + sh 'node --version' } } } From 371a76d90e930cf85792ac1e0fdc6d9199a83906 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Mon, 11 Apr 2022 17:50:52 +0530 Subject: [PATCH 52/59] Update Jenkinsfile --- Jenkinsfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index d370161e9..15f53f415 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -1,11 +1,11 @@ pipeline { agent { - docker { image 'node:16.13.1-alpine' } + docker { image 'build:1.0' } } stages { stage('Test') { steps { - sh 'node --version' + sh 'maven --version' } } } From c5ae78ff01a15aac65a6b5674b9ed7cd34bb86b6 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Mon, 11 Apr 2022 17:56:36 +0530 Subject: [PATCH 53/59] Update Jenkinsfile --- Jenkinsfile | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 15f53f415..b3e15f38c 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -1,11 +1,15 @@ pipeline { - agent { - docker { image 'build:1.0' } - } + agent any stages { - stage('Test') { + stage('Build') { + agent { + docker { + image 'gradle:6.7-jdk11' + reuseNode true + } + } steps { - sh 'maven --version' + sh 'gradle --version' } } } From 769fef18b13109e96e65abe83f3919e5241085ea Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Mon, 11 Apr 2022 17:59:03 +0530 Subject: [PATCH 54/59] Update Jenkinsfile --- Jenkinsfile | 1 + 1 file changed, 1 insertion(+) diff --git a/Jenkinsfile b/Jenkinsfile index b3e15f38c..508f47a2a 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -4,6 +4,7 @@ pipeline { stage('Build') { agent { docker { + tool name: 'docker', type: 'dockerTool' image 'gradle:6.7-jdk11' reuseNode true } From 862ffb1e6e22675e8ae2886bb38dec49be57631b Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Mon, 11 Apr 2022 18:00:08 +0530 Subject: [PATCH 55/59] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 508f47a2a..39f102a40 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -1,10 +1,10 @@ pipeline { agent any stages { + [ tool name: 'docker', type: 'dockerTool' ] stage('Build') { agent { docker { - tool name: 'docker', type: 'dockerTool' image 'gradle:6.7-jdk11' reuseNode true } From 006e3133cba447a3e75b00e00e9cc32e119da961 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Mon, 11 Apr 2022 18:04:35 +0530 Subject: [PATCH 56/59] Update Jenkinsfile --- Jenkinsfile | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 39f102a40..3c5717c36 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -1,16 +1,12 @@ pipeline { - agent any + agent { + docker { image 'node:16.13.1-alpine' } + } stages { - [ tool name: 'docker', type: 'dockerTool' ] - stage('Build') { - agent { - docker { - image 'gradle:6.7-jdk11' - reuseNode true - } - } + stage('Test') { steps { - sh 'gradle --version' + tool name: 'docker', type: 'dockerTool' + sh 'node --version' } } } From 49e817aa19c534224b3a1c10957733d45110f1de Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Mon, 11 Apr 2022 18:53:22 +0530 Subject: [PATCH 57/59] Update Jenkinsfile --- Jenkinsfile | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/Jenkinsfile b/Jenkinsfile index 3c5717c36..0663a4bb4 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -1,4 +1,11 @@ pipeline { + agent ( label 'last1' ) + stages { + stage('check') { + steps { + sh ' mkdir -p folder ' + } + } agent { docker { image 'node:16.13.1-alpine' } } From 3219acaf686f85ef07f586bd51442982c391f1a3 Mon Sep 17 00:00:00 2001 From: Lohith raje urs <101534920+Lohras@users.noreply.github.com> Date: Mon, 11 Apr 2022 19:05:09 +0530 Subject: [PATCH 58/59] Update Jenkinsfile --- Jenkinsfile | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 0663a4bb4..d7d40ab47 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -1,15 +1,14 @@ pipeline { agent ( label 'last1' ) - stages { - stage('check') { - steps { - sh ' mkdir -p folder ' + stages { + stage('check') { + steps { + sh ' mkdir -p folder ' } } agent { docker { image 'node:16.13.1-alpine' } } - stages { stage('Test') { steps { tool name: 'docker', type: 'dockerTool' From af81f2118c8ac18605106978deceac132680a35f Mon Sep 17 00:00:00 2001 From: maheshmavathur <96064206+maheshmavathur@users.noreply.github.com> Date: Mon, 11 Apr 2022 19:15:42 +0530 Subject: [PATCH 59/59] Update Jenkinsfile --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index d7d40ab47..1183b9228 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -11,7 +11,7 @@ pipeline { } stage('Test') { steps { - tool name: 'docker', type: 'dockerTool' + sh 'node --version' } }