From 2e69401e2d2ea34d47f62142d07f4c2a6a1837ca Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sat, 11 Feb 2023 14:09:12 +0530
Subject: [PATCH 01/39] sonar stage error fix
---
Jenkinsfile | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index a2df42b1..53d8bfdd 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -6,7 +6,7 @@ pipeline{
stages{
stage("sonar quality check"){
agent {
- docker {
+ docker{
image 'openjdk:11'
}
}
@@ -27,7 +27,7 @@ pipeline{
}
}
}
- stage("docker build & docker push"){
+ /* stage("docker build & docker push"){
steps{
script{
withCredentials([string(credentialsId: 'docker_pass', variable: 'docker_password')]) {
@@ -101,8 +101,8 @@ pipeline{
}
}
}
- }
- }
+ } /*
+ }
post {
always {
From 6c7bc2820bccf32696bf6419e0e85e0dab7f1f2f Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sat, 11 Feb 2023 14:15:13 +0530
Subject: [PATCH 02/39] sonar stage error fix
---
Jenkinsfile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index 53d8bfdd..62b8216c 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -101,7 +101,7 @@ pipeline{
}
}
}
- } /*
+ } */
}
post {
From 93f6e5af3d304c1621cea853fb6e9b096b11ba74 Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sat, 11 Feb 2023 14:19:10 +0530
Subject: [PATCH 03/39] sonar stage error fix
---
Jenkinsfile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index 62b8216c..49877bd2 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -6,7 +6,7 @@ pipeline{
stages{
stage("sonar quality check"){
agent {
- docker{
+ docker {
image 'openjdk:11'
}
}
From 272e4f35e0bce77559995b28127d23fefa8ba445 Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sat, 11 Feb 2023 16:07:08 +0530
Subject: [PATCH 04/39] sonar stage error fix
---
Jenkinsfile | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index 49877bd2..7d5f6503 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -10,7 +10,7 @@ pipeline{
image 'openjdk:11'
}
}
- steps{
+ /*steps{
script{
withSonarQubeEnv(credentialsId: 'sonar-token') {
sh 'chmod +x gradlew'
@@ -25,7 +25,7 @@ pipeline{
}
}
- }
+ }/*
}
/* stage("docker build & docker push"){
steps{
From d05c2ffb84c8b54c18e1842812e47af2915da0d1 Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sat, 11 Feb 2023 16:09:31 +0530
Subject: [PATCH 05/39] sonar stage error fix
---
Jenkinsfile | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index 7d5f6503..294b4a0e 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -10,7 +10,7 @@ pipeline{
image 'openjdk:11'
}
}
- /*steps{
+ /* steps{
script{
withSonarQubeEnv(credentialsId: 'sonar-token') {
sh 'chmod +x gradlew'
@@ -25,7 +25,7 @@ pipeline{
}
}
- }/*
+ }*/
}
/* stage("docker build & docker push"){
steps{
From d20546bf70a702b8d144e45821c4ae126c03d8dd Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sat, 11 Feb 2023 16:11:32 +0530
Subject: [PATCH 06/39] sonar stage error fix
---
Jenkinsfile | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index 294b4a0e..11e1b694 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -10,22 +10,22 @@ pipeline{
image 'openjdk:11'
}
}
- /* steps{
+ steps{
script{
withSonarQubeEnv(credentialsId: 'sonar-token') {
sh 'chmod +x gradlew'
sh './gradlew sonarqube'
}
- timeout(time: 1, unit: 'HOURS') {
+ /* timeout(time: 1, unit: 'HOURS') {
def qg = waitForQualityGate()
if (qg.status != 'OK') {
error "Pipeline aborted due to quality gate failure: ${qg.status}"
}
- }
+ } */
}
- }*/
+ }
}
/* stage("docker build & docker push"){
steps{
From 4137e9223edd83e317f6884a42b44def0f7c14c6 Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sat, 11 Feb 2023 16:25:36 +0530
Subject: [PATCH 07/39] sonar stage error fix
---
Jenkinsfile | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index 11e1b694..418ce0e3 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -1,8 +1,8 @@
pipeline{
agent any
- environment{
+ /* environment{
VERSION = "${env.BUILD_ID}"
- }
+ } */
stages{
stage("sonar quality check"){
agent {
From b44b407d4325dcb67080a1e07a1f9b62d92b0ffd Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sat, 11 Feb 2023 16:37:54 +0530
Subject: [PATCH 08/39] sonar stage error fix
---
Jenkinsfile | 16 ++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index 418ce0e3..e0c634fb 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -1,10 +1,10 @@
pipeline{
agent any
- /* environment{
+ environment{
VERSION = "${env.BUILD_ID}"
- } */
+ }
stages{
- stage("sonar quality check"){
+ /*stage("sonar quality check"){
agent {
docker {
image 'openjdk:11'
@@ -17,17 +17,17 @@ pipeline{
sh './gradlew sonarqube'
}
- /* timeout(time: 1, unit: 'HOURS') {
+ timeout(time: 1, unit: 'HOURS') {
def qg = waitForQualityGate()
if (qg.status != 'OK') {
error "Pipeline aborted due to quality gate failure: ${qg.status}"
}
- } */
+ }
}
}
- }
- /* stage("docker build & docker push"){
+ } */
+ stage("docker build & docker push"){
steps{
script{
withCredentials([string(credentialsId: 'docker_pass', variable: 'docker_password')]) {
@@ -41,7 +41,7 @@ pipeline{
}
}
}
- stage('indentifying misconfigs using datree in helm charts'){
+ /*stage('indentifying misconfigs using datree in helm charts'){
steps{
script{
From c35d5b44396c53ca26743244c9002cd47a096875 Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sat, 11 Feb 2023 17:16:03 +0530
Subject: [PATCH 09/39] sonar stage error fix
---
Jenkinsfile | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index e0c634fb..eb0d7a02 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -4,7 +4,7 @@ pipeline{
VERSION = "${env.BUILD_ID}"
}
stages{
- /*stage("sonar quality check"){
+ stage("sonar quality check"){
agent {
docker {
image 'openjdk:11'
@@ -26,8 +26,8 @@ pipeline{
}
}
- } */
- stage("docker build & docker push"){
+ }
+ /*stage("docker build & docker push"){
steps{
script{
withCredentials([string(credentialsId: 'docker_pass', variable: 'docker_password')]) {
@@ -41,7 +41,7 @@ pipeline{
}
}
}
- /*stage('indentifying misconfigs using datree in helm charts'){
+ stage('indentifying misconfigs using datree in helm charts'){
steps{
script{
From 8a2339ca7397524cbd3ac20ed1d94de309c652e6 Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sat, 11 Feb 2023 17:42:13 +0530
Subject: [PATCH 10/39] sonar stage error fix
---
Jenkinsfile | 1 +
1 file changed, 1 insertion(+)
diff --git a/Jenkinsfile b/Jenkinsfile
index eb0d7a02..93d6544e 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -12,6 +12,7 @@ pipeline{
}
steps{
script{
+ // withSonarQubeEnv(credentialsId: 'sonar-token')
withSonarQubeEnv(credentialsId: 'sonar-token') {
sh 'chmod +x gradlew'
sh './gradlew sonarqube'
From 843cf0b7134888d746223e09a8c72b8cc92e3a42 Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sat, 11 Feb 2023 17:45:49 +0530
Subject: [PATCH 11/39] sonar stage error fix
---
Jenkinsfile | 1 -
1 file changed, 1 deletion(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index 93d6544e..eb0d7a02 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -12,7 +12,6 @@ pipeline{
}
steps{
script{
- // withSonarQubeEnv(credentialsId: 'sonar-token')
withSonarQubeEnv(credentialsId: 'sonar-token') {
sh 'chmod +x gradlew'
sh './gradlew sonarqube'
From d745dd10c14b854ffdc2753858263d47597670ca Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sat, 11 Feb 2023 18:40:23 +0530
Subject: [PATCH 12/39] sonar stage error fix
---
Jenkinsfile | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index eb0d7a02..4a997256 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -17,12 +17,12 @@ pipeline{
sh './gradlew sonarqube'
}
- timeout(time: 1, unit: 'HOURS') {
+ /* timeout(time: 1, unit: 'HOURS') {
def qg = waitForQualityGate()
if (qg.status != 'OK') {
error "Pipeline aborted due to quality gate failure: ${qg.status}"
}
- }
+ } */
}
}
From 2a8c2034f8f93d59a72e5493ef6a1c2c30beb5c0 Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sat, 11 Feb 2023 18:53:58 +0530
Subject: [PATCH 13/39] sonar stage error fix
---
Jenkinsfile | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index 4a997256..9dee7e2f 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -5,11 +5,11 @@ pipeline{
}
stages{
stage("sonar quality check"){
- agent {
+ /* agent {
docker {
image 'openjdk:11'
}
- }
+ } */
steps{
script{
withSonarQubeEnv(credentialsId: 'sonar-token') {
From 18b6f6b4a84f2bf0751b03780f99f5e2fed53dda Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sat, 11 Feb 2023 18:57:25 +0530
Subject: [PATCH 14/39] sonar stage error fix
---
Jenkinsfile | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index 9dee7e2f..a10ad691 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -104,9 +104,9 @@ pipeline{
} */
}
- post {
+ /* post {
always {
mail bcc: '', body: "
Project: ${env.JOB_NAME}
Build Number: ${env.BUILD_NUMBER}
URL de build: ${env.BUILD_URL}", cc: '', charset: 'UTF-8', from: '', mimeType: 'text/html', replyTo: '', subject: "${currentBuild.result} CI: Project name -> ${env.JOB_NAME}", to: "deekshith.snsep@gmail.com";
}
- }
+ }/*
}
From fa68e536d3088e261122ef57e0a047940f5f3070 Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sat, 11 Feb 2023 19:03:14 +0530
Subject: [PATCH 15/39] sonar stage error fix
---
Jenkinsfile | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index a10ad691..b5b6d518 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -104,9 +104,9 @@ pipeline{
} */
}
- /* post {
+ /* post {
always {
mail bcc: '', body: "
Project: ${env.JOB_NAME}
Build Number: ${env.BUILD_NUMBER}
URL de build: ${env.BUILD_URL}", cc: '', charset: 'UTF-8', from: '', mimeType: 'text/html', replyTo: '', subject: "${currentBuild.result} CI: Project name -> ${env.JOB_NAME}", to: "deekshith.snsep@gmail.com";
}
- }/*
-}
+ } */
+}
\ No newline at end of file
From d862cdad401b11d30d8cd54acc7b91bf8a1569b6 Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sat, 11 Feb 2023 19:07:58 +0530
Subject: [PATCH 16/39] sonar stage error fix
---
Jenkinsfile | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index b5b6d518..7b6aff07 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -17,12 +17,12 @@ pipeline{
sh './gradlew sonarqube'
}
- /* timeout(time: 1, unit: 'HOURS') {
+ timeout(time: 1, unit: 'HOURS') {
def qg = waitForQualityGate()
if (qg.status != 'OK') {
error "Pipeline aborted due to quality gate failure: ${qg.status}"
}
- } */
+ }
}
}
From c67baa581c23946828ecaac222a5970175333fb6 Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sat, 11 Feb 2023 19:24:28 +0530
Subject: [PATCH 17/39] sonar stage error fix
---
Jenkinsfile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index 7b6aff07..3bd3def9 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -17,7 +17,7 @@ pipeline{
sh './gradlew sonarqube'
}
- timeout(time: 1, unit: 'HOURS') {
+ timeout(time: 2, unit: 'MINUTES') {
def qg = waitForQualityGate()
if (qg.status != 'OK') {
error "Pipeline aborted due to quality gate failure: ${qg.status}"
From ec761899d86b722c2f85ced3e2113d42eb8c9011 Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sat, 11 Feb 2023 21:10:30 +0530
Subject: [PATCH 18/39] sonar stage error fix
---
Jenkinsfile | 16 ++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index 3bd3def9..0bfbe14b 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -17,31 +17,31 @@ pipeline{
sh './gradlew sonarqube'
}
- timeout(time: 2, unit: 'MINUTES') {
+ /* timeout(time: 2, unit: 'MINUTES') {
def qg = waitForQualityGate()
if (qg.status != 'OK') {
error "Pipeline aborted due to quality gate failure: ${qg.status}"
}
- }
+ } */
}
}
}
- /*stage("docker build & docker push"){
+ stage("docker build & docker push"){
steps{
script{
withCredentials([string(credentialsId: 'docker_pass', variable: 'docker_password')]) {
sh '''
- docker build -t 34.125.214.226:8083/springapp:${VERSION} .
- docker login -u admin -p $docker_password 34.125.214.226:8083
- docker push 34.125.214.226:8083/springapp:${VERSION}
- docker rmi 34.125.214.226:8083/springapp:${VERSION}
+ docker build -t http://35.222.47.82/:8083/springapp:${VERSION} .
+ docker login -u admin -p $docker_password http://35.222.47.82/:8083
+ docker push http://35.222.47.82/:8083/springapp:${VERSION}
+ docker rmi http://35.222.47.82/:8083/springapp:${VERSION}
'''
}
}
}
}
- stage('indentifying misconfigs using datree in helm charts'){
+ /* stage('indentifying misconfigs using datree in helm charts'){
steps{
script{
From 459f782c70ac7fbced652ae6fa2a4ea5a3bcda28 Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sat, 11 Feb 2023 21:16:40 +0530
Subject: [PATCH 19/39] sonar stage error fix
---
Jenkinsfile | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index 0bfbe14b..57258f2f 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -32,10 +32,10 @@ pipeline{
script{
withCredentials([string(credentialsId: 'docker_pass', variable: 'docker_password')]) {
sh '''
- docker build -t http://35.222.47.82/:8083/springapp:${VERSION} .
- docker login -u admin -p $docker_password http://35.222.47.82/:8083
- docker push http://35.222.47.82/:8083/springapp:${VERSION}
- docker rmi http://35.222.47.82/:8083/springapp:${VERSION}
+ docker build -t 35.222.47.82/:8083/springapp:${VERSION} .
+ docker login -u admin -p $docker_password 35.222.47.82/:8083
+ docker push 35.222.47.82/:8083/springapp:${VERSION}
+ docker rmi 35.222.47.82/:8083/springapp:${VERSION}
'''
}
}
From 7728af4706a182ea8a72a2eba4a5e04a15a80cca Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sat, 11 Feb 2023 21:48:49 +0530
Subject: [PATCH 20/39] sonar stage error fix
---
Jenkinsfile | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index 57258f2f..0fab2d27 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -32,10 +32,10 @@ pipeline{
script{
withCredentials([string(credentialsId: 'docker_pass', variable: 'docker_password')]) {
sh '''
- docker build -t 35.222.47.82/:8083/springapp:${VERSION} .
- docker login -u admin -p $docker_password 35.222.47.82/:8083
- docker push 35.222.47.82/:8083/springapp:${VERSION}
- docker rmi 35.222.47.82/:8083/springapp:${VERSION}
+ docker build -t 35.222.47.82:8083/springapp:${VERSION} .
+ docker login -u admin -p $docker_password 35.222.47.82:8083
+ docker push 35.222.47.82:8083/springapp:${VERSION}
+ docker rmi 35.222.47.82:8083/springapp:${VERSION}
'''
}
}
From e1fbe7d489469b3c18c85405069e5617d4ce7717 Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sat, 11 Feb 2023 22:09:49 +0530
Subject: [PATCH 21/39] sonar stage error fix
---
Jenkinsfile | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index 0fab2d27..f482ca69 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -41,7 +41,7 @@ pipeline{
}
}
}
- /* stage('indentifying misconfigs using datree in helm charts'){
+ stage('indentifying misconfigs using datree in helm charts'){
steps{
script{
@@ -53,7 +53,7 @@ pipeline{
}
}
}
- stage("pushing the helm charts to nexus"){
+ /* stage("pushing the helm charts to nexus"){
steps{
script{
withCredentials([string(credentialsId: 'docker_pass', variable: 'docker_password')]) {
From daa9085ecf22e01e9b36967555c03ffccd1b3bcb Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sun, 12 Feb 2023 10:24:00 +0530
Subject: [PATCH 22/39] sonar stage error fix
---
Jenkinsfile | 16 ++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index f482ca69..d535b58b 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -32,16 +32,16 @@ pipeline{
script{
withCredentials([string(credentialsId: 'docker_pass', variable: 'docker_password')]) {
sh '''
- docker build -t 35.222.47.82:8083/springapp:${VERSION} .
- docker login -u admin -p $docker_password 35.222.47.82:8083
- docker push 35.222.47.82:8083/springapp:${VERSION}
- docker rmi 35.222.47.82:8083/springapp:${VERSION}
+ docker build -t 35.222.146.161:8083/springapp:${VERSION} .
+ docker login -u admin -p $docker_password 35.222.146.161:8083
+ docker push 35.222.146.161:8083/springapp:${VERSION}
+ docker rmi 35.222.146.161:8083/springapp:${VERSION}
'''
}
}
}
}
- stage('indentifying misconfigs using datree in helm charts'){
+ /* stage('indentifying misconfigs using datree in helm charts'){
steps{
script{
@@ -52,8 +52,8 @@ pipeline{
}
}
}
- }
- /* stage("pushing the helm charts to nexus"){
+ } */
+ stage("pushing the helm charts to nexus"){
steps{
script{
withCredentials([string(credentialsId: 'docker_pass', variable: 'docker_password')]) {
@@ -69,7 +69,7 @@ pipeline{
}
}
- stage('manual approval'){
+ /* stage('manual approval'){
steps{
script{
timeout(10) {
From 97851b3d1fc8481a7fc98e6fff8073b4b650b7da Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sun, 12 Feb 2023 10:49:52 +0530
Subject: [PATCH 23/39] sonar stage error fix
---
Jenkinsfile | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index d535b58b..b440d30f 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -5,11 +5,11 @@ pipeline{
}
stages{
stage("sonar quality check"){
- /* agent {
+ agent {
docker {
image 'openjdk:11'
}
- } */
+ }
steps{
script{
withSonarQubeEnv(credentialsId: 'sonar-token') {
From a150adb4e624788238ef4838838f08a49cef0b43 Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sun, 12 Feb 2023 11:02:02 +0530
Subject: [PATCH 24/39] sonar stage error fix
---
Jenkinsfile | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index b440d30f..6c7c92f8 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -5,11 +5,11 @@ pipeline{
}
stages{
stage("sonar quality check"){
- agent {
+ /* agent {
docker {
image 'openjdk:11'
}
- }
+ } */
steps{
script{
withSonarQubeEnv(credentialsId: 'sonar-token') {
From e29382669d6e86c57ce86f5231884cf99002170e Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sun, 12 Feb 2023 11:25:48 +0530
Subject: [PATCH 25/39] sonar stage error fix
---
Jenkinsfile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index 6c7c92f8..50472a40 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -14,7 +14,7 @@ pipeline{
script{
withSonarQubeEnv(credentialsId: 'sonar-token') {
sh 'chmod +x gradlew'
- sh './gradlew sonarqube'
+ sh './gradlew sonarqube x'
}
/* timeout(time: 2, unit: 'MINUTES') {
From 7516b07eb4587a44d3a0104d318b82da33da4320 Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sun, 12 Feb 2023 11:26:58 +0530
Subject: [PATCH 26/39] sonar stage error fix
---
Jenkinsfile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index 50472a40..6c7c92f8 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -14,7 +14,7 @@ pipeline{
script{
withSonarQubeEnv(credentialsId: 'sonar-token') {
sh 'chmod +x gradlew'
- sh './gradlew sonarqube x'
+ sh './gradlew sonarqube'
}
/* timeout(time: 2, unit: 'MINUTES') {
From b7eb244bbb539a756c0c51220c5ca5cb099ebe7b Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sun, 12 Feb 2023 12:05:02 +0530
Subject: [PATCH 27/39] sonar stage error fix
---
Jenkinsfile | 1 +
1 file changed, 1 insertion(+)
diff --git a/Jenkinsfile b/Jenkinsfile
index 6c7c92f8..72271b23 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -30,6 +30,7 @@ pipeline{
stage("docker build & docker push"){
steps{
script{
+ // withCredentials([string(credentialsId: 'docker_pass', variable: 'docker_password')])
withCredentials([string(credentialsId: 'docker_pass', variable: 'docker_password')]) {
sh '''
docker build -t 35.222.146.161:8083/springapp:${VERSION} .
From 881c3ab286e5d00132acad076f2d32f1bf758b92 Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sun, 12 Feb 2023 12:54:00 +0530
Subject: [PATCH 28/39] sonar stage error fix
---
Jenkinsfile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index 72271b23..f7b10739 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -62,7 +62,7 @@ pipeline{
sh '''
helmversion=$( helm show chart myapp | grep version | cut -d: -f 2 | tr -d ' ')
tar -czvf myapp-${helmversion}.tgz myapp/
- curl -u admin:$docker_password http://34.125.214.226:8081/repository/helm-hosted/ --upload-file myapp-${helmversion}.tgz -v
+ curl -u admin:$docker_password http://35.222.146.161:8083/repository/helm-hosted/ --upload-file myapp-${helmversion}.tgz -v
'''
}
}
From 6852cb55d1c6c388b082d2d5c1bd671a9495d90b Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sun, 12 Feb 2023 13:06:09 +0530
Subject: [PATCH 29/39] sonar stage error fix
---
Jenkinsfile | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index f7b10739..a1674f3e 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -79,21 +79,21 @@ pipeline{
}
}
}
- }
+ }*/
stage('Deploying application on k8s cluster') {
steps {
script{
withCredentials([kubeconfigFile(credentialsId: 'kubernetes-config', variable: 'KUBECONFIG')]) {
dir('kubernetes/') {
- sh 'helm upgrade --install --set image.repository="34.125.214.226:8083/springapp" --set image.tag="${VERSION}" myjavaapp myapp/ '
+ sh 'helm upgrade --install --set image.repository="35.222.146.161:8083/springapp" --set image.tag="${VERSION}" myjavaapp myapp/ '
}
}
}
}
}
- stage('verifying app deployment'){
+ /* stage('verifying app deployment'){
steps{
script{
withCredentials([kubeconfigFile(credentialsId: 'kubernetes-config', variable: 'KUBECONFIG')]) {
From e795072fee4e876f44642a25612b36eead02f108 Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sun, 12 Feb 2023 20:40:45 +0530
Subject: [PATCH 30/39] sonar stage error fix
---
Jenkinsfile | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index a1674f3e..438fe72a 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -5,11 +5,11 @@ pipeline{
}
stages{
stage("sonar quality check"){
- /* agent {
+ agent {
docker {
image 'openjdk:11'
}
- } */
+ }
steps{
script{
withSonarQubeEnv(credentialsId: 'sonar-token') {
@@ -81,7 +81,7 @@ pipeline{
}
}*/
- stage('Deploying application on k8s cluster') {
+ /* stage('Deploying application on k8s cluster') {
steps {
script{
withCredentials([kubeconfigFile(credentialsId: 'kubernetes-config', variable: 'KUBECONFIG')]) {
@@ -91,7 +91,7 @@ pipeline{
}
}
}
- }
+ }*/
/* stage('verifying app deployment'){
steps{
From c013620f08d9a8e909fea4c10f1fecb3bc774f08 Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sun, 12 Feb 2023 21:00:05 +0530
Subject: [PATCH 31/39] sonar stage error fix
---
Jenkinsfile | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index 438fe72a..b4734376 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -4,12 +4,12 @@ pipeline{
VERSION = "${env.BUILD_ID}"
}
stages{
- stage("sonar quality check"){
+ /* stage("sonar quality check"){
agent {
docker {
image 'openjdk:11'
}
- }
+ } */
steps{
script{
withSonarQubeEnv(credentialsId: 'sonar-token') {
From 69d36c87c4e35c73d1cba9471e6150bdf03dd529 Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Sun, 12 Feb 2023 21:03:53 +0530
Subject: [PATCH 32/39] sonar stage error fix
---
Jenkinsfile | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index b4734376..b78e5487 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -4,8 +4,8 @@ pipeline{
VERSION = "${env.BUILD_ID}"
}
stages{
- /* stage("sonar quality check"){
- agent {
+ stage("sonar quality check"){
+ /* agent {
docker {
image 'openjdk:11'
}
From 4ff2edbd9c2ddb0109399996bd87c9c3023c07ee Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Mon, 13 Feb 2023 10:09:17 +0530
Subject: [PATCH 33/39] sonar stage error fix
---
Jenkinsfile | 4 ++--
kubernetes connect | 24 ++++++++++++++++++++++++
2 files changed, 26 insertions(+), 2 deletions(-)
create mode 100644 kubernetes connect
diff --git a/Jenkinsfile b/Jenkinsfile
index b78e5487..c14b556c 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -81,7 +81,7 @@ pipeline{
}
}*/
- /* stage('Deploying application on k8s cluster') {
+ stage('Deploying application on k8s cluster') {
steps {
script{
withCredentials([kubeconfigFile(credentialsId: 'kubernetes-config', variable: 'KUBECONFIG')]) {
@@ -91,7 +91,7 @@ pipeline{
}
}
}
- }*/
+ }
/* stage('verifying app deployment'){
steps{
diff --git a/kubernetes connect b/kubernetes connect
new file mode 100644
index 00000000..1cfed8d4
--- /dev/null
+++ b/kubernetes connect
@@ -0,0 +1,24 @@
+name: Deploy to Kubernetes
+
+on:
+ push:
+ branches: [ development ]
+ pull_request:
+ branches: [ development ]
+
+jobs:
+ deploy:
+ name: Deploy to Kubernetes
+ runs-on: ubuntu-latest
+ steps:
+ - name: Checkout code
+ uses: actions/checkout@v2
+ - name: Create kubeconfig
+ run: |
+ mkdir ${HOME}/.kube
+ echo ${{ secrets.KUBE_CONFIG }} | base64 --decode > ${HOME}/.kube/config
+ cat ${HOME}/.kube/config
+ - name: Use context
+ run: kubectl config use-context octobay-api
+ - name: Deploy to K8s
+ run: kubectl apply -f k8s/
\ No newline at end of file
From cf170f177dd73166fda60a395cf132676c4ee745 Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Wed, 5 Apr 2023 16:03:24 +0530
Subject: [PATCH 34/39] Update ci.yml
---
.github/workflows/ci.yml | 21 +++------------------
1 file changed, 3 insertions(+), 18 deletions(-)
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index f02131ce..00dad04c 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -4,8 +4,8 @@ on:
pull_request:
branches: [ main ]
-env:
- DATREE_TOKEN: ${{ secrets.DATREE_TOKEN }}
+#env:
+# DATREE_TOKEN: ${{ secrets.DATREE_TOKEN }}
jobs:
build:
@@ -24,21 +24,6 @@ jobs:
run: chmod +x gradlew
- name: Build with Gradle
run: ./gradlew build
- - name: SonarQube Scan
- uses: sonarsource/sonarqube-scan-action@master
- env:
- SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
- SONAR_HOST_URL: ${{ secrets.SONAR_HOST_URL }}
- - name: SonarQube Quality Gate check
- uses: sonarsource/sonarqube-quality-gate-action@master
- # Force to fail step after specific time
- timeout-minutes: 5
- env:
- SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
- - name: Install Datree
- run: curl https://get.datree.io | /bin/bash
-
- - name: Run Datree's policy check
- run: datree test kube.yaml
+
From da82e3980f2e658b675d24b2399543bc378cae22 Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Wed, 5 Apr 2023 16:07:32 +0530
Subject: [PATCH 35/39] Update kube.yaml
---
kube.yaml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/kube.yaml b/kube.yaml
index d0058111..1e1aebbb 100644
--- a/kube.yaml
+++ b/kube.yaml
@@ -46,7 +46,7 @@ spec:
- name: registry-secret
containers:
- name: myapp
- image: imagename
+ image: ngnix:1.0
command: ["/bin/sh"]
args: ["-c","sh /usr/local/tomcat/bin/startup.sh;while true; do echo hello; sleep 10;done"]
imagePullPolicy: IfNotPresent
From 3a68e873a0d8994f6ad3a29af3dcfe9d9da1c265 Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Wed, 5 Apr 2023 16:15:10 +0530
Subject: [PATCH 36/39] Update kube.yaml
---
kube.yaml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/kube.yaml b/kube.yaml
index 1e1aebbb..1f366a4f 100644
--- a/kube.yaml
+++ b/kube.yaml
@@ -46,7 +46,7 @@ spec:
- name: registry-secret
containers:
- name: myapp
- image: ngnix:1.0
+ image: ngnix
command: ["/bin/sh"]
args: ["-c","sh /usr/local/tomcat/bin/startup.sh;while true; do echo hello; sleep 10;done"]
imagePullPolicy: IfNotPresent
From 0cb3701f329d07dc1fead313c0b76b099ae69dfe Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Wed, 5 Apr 2023 16:20:03 +0530
Subject: [PATCH 37/39] Update kube.yaml
---
kube.yaml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/kube.yaml b/kube.yaml
index 1f366a4f..1e1aebbb 100644
--- a/kube.yaml
+++ b/kube.yaml
@@ -46,7 +46,7 @@ spec:
- name: registry-secret
containers:
- name: myapp
- image: ngnix
+ image: ngnix:1.0
command: ["/bin/sh"]
args: ["-c","sh /usr/local/tomcat/bin/startup.sh;while true; do echo hello; sleep 10;done"]
imagePullPolicy: IfNotPresent
From d9f01bea98d23cc3769dd136d938a1941e1cfabb Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Wed, 5 Apr 2023 16:22:54 +0530
Subject: [PATCH 38/39] Update kube.yaml
testing
---
kube.yaml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/kube.yaml b/kube.yaml
index 1e1aebbb..2e517626 100644
--- a/kube.yaml
+++ b/kube.yaml
@@ -46,7 +46,7 @@ spec:
- name: registry-secret
containers:
- name: myapp
- image: ngnix:1.0
+ image: ngnix:2.0
command: ["/bin/sh"]
args: ["-c","sh /usr/local/tomcat/bin/startup.sh;while true; do echo hello; sleep 10;done"]
imagePullPolicy: IfNotPresent
From a1f35832f09bfa8f0d6b712fdad297db8f4343a2 Mon Sep 17 00:00:00 2001
From: gaganbabu <92263787+gaganbabu@users.noreply.github.com>
Date: Wed, 5 Apr 2023 16:25:48 +0530
Subject: [PATCH 39/39] Update kube.yaml
---
kube.yaml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/kube.yaml b/kube.yaml
index 2e517626..c8912fc6 100644
--- a/kube.yaml
+++ b/kube.yaml
@@ -46,7 +46,7 @@ spec:
- name: registry-secret
containers:
- name: myapp
- image: ngnix:2.0
+ image: ngnix:3.0
command: ["/bin/sh"]
args: ["-c","sh /usr/local/tomcat/bin/startup.sh;while true; do echo hello; sleep 10;done"]
imagePullPolicy: IfNotPresent