Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Patch 3 #31

Open
wants to merge 31 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
294da5b
Update Jenkinsfile
legah2045 Aug 22, 2021
7934dc5
Update pom.xml
mylandmarkpay Sep 4, 2021
9276493
Update pom.xml
mylandmarkpay Sep 4, 2021
f2274bc
Update pom.xml
mylandmarkpay Sep 4, 2021
8c8e3a8
Update pom.xml
mylandmarkpay Sep 6, 2021
3ccb82b
Update home.jsp
mylandmarkpay Sep 7, 2021
c716dda
Update home.jsp
mylandmarkpay Sep 7, 2021
a20d44e
Update Dockerfile
mylandmarkpay Sep 8, 2021
283ee4e
Update Dockerfile
mylandmarkpay Sep 8, 2021
fad4863
Update home.jsp
mylandmarkpay Sep 11, 2021
6673341
Update home.jsp
mylandmarkpay Sep 11, 2021
a6f83e7
Update home.jsp
mylandmarkpay Sep 11, 2021
6780709
Create Jenkinsfile-ebay
mylandmarkpay Sep 11, 2021
5c04d92
Update Jenkinsfile-ebay
mylandmarkpay Sep 11, 2021
bd52f9f
Update Jenkinsfile-ebay
mylandmarkpay Sep 11, 2021
441a65e
Update Jenkinsfile-ebay
mylandmarkpay Sep 11, 2021
bb17c5d
testing
mylandmarkpay Sep 18, 2021
08df69a
Create paypal.groovy
mylandmarkpay Sep 18, 2021
60acfae
Update Dockerfile
mylandmarkpay Sep 21, 2021
cf81212
Delete src/main directory
legah2045 Sep 24, 2021
46ac861
Add files via upload
legah2045 Sep 24, 2021
0a0b140
Add files via upload
legah2045 Sep 24, 2021
50e5c9e
Update pom.xml
legah2045 Jan 14, 2022
7ad5e55
Update pom.xml
legah2045 Jan 14, 2022
052edc7
Update pom.xml
legah2045 Jan 14, 2022
975a103
Update pom.xml
legah2045 Jan 15, 2022
590a439
Update Dockerfile
legah2045 Jan 15, 2022
5d66a2c
Create Jenkinsfile_docker
legah2045 Jan 15, 2022
45ffe22
Update pom.xml
oibiyemi Jan 17, 2022
bbdc3bd
Merge branch 'mylandmarktechs:master' into patch-3
oibiyemi Jan 17, 2022
e8aeb6c
Update pom.xml
oibiyemi Jan 17, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
FROM tomcat:8.0.20-jre8
# Dummy text to test
COPY target/maven-web-application*.war /usr/local/tomcat/webapps/maven-web-application.war
### Good stuff
COPY target/*.war /usr/local/tomcat/webapps/maven-web-app.war
6 changes: 3 additions & 3 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -43,11 +43,11 @@ node

stage('EmailNotification')
{
mail bcc: 'devopstrainingblr@gmail.com', body: '''Build is over
mail bcc: 'mylandmarktech@gmail.com', body: '''Build is over

Thanks,
Mithun Technologies,
9980923226.''', cc: 'devopstrainingblr@gmail.com', from: '', replyTo: '', subject: 'Build is over!!', to: 'devopstrainingblr@gmail.com'
Landmark Technologies,
+14372152483.''', cc: 'mylandmarktech@gmail.com', from: '', replyTo: '', subject: 'Build is over!!', to: 'mylandmarktech@gmail.com'
}
*/

Expand Down
41 changes: 41 additions & 0 deletions Jenkinsfile-ebay
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
node {
def mavenHome = tool name: 'maven3.8.2'
stage('1-Clone') {
git credentialsId: 'GitHUB-CREDENTIALS', url: 'https://github.com/Landmark-Technologies/maven-web-application'
}
stage('2-mavenBuild') {
sh "${mavenHome}/bin/mvn clean package"
}
/*
stage('3-CodeQuality') {
sh "${mavenHome}/bin/mvn sonar:sonar"
}
stage('4-UploadArticats') {
sh "${mavenHome}/bin/mvn deploy"
}

stage('5-Deploy-UAT') {
deploy adapters: [tomcat9(credentialsId: 'deploy', path: '', url: 'http://54.204.83.221:8000/')], contextPath: null, war: 'target/*.war'
}
stage('6-EmailN') {
emailext body: '''Hello Everyone,

Build from Ebay pipeline project.

Landmark Tecxhnologies''', subject: 'Build status', to: 'developers'
}
stage('Approval'){
timeout(time:8, unit: 'HOURS' ) {
input message: 'Please verify and approve'
}

}
stage('prod-Deploy'){
deploy adapters: [tomcat9(credentialsId: 'deploy', path: '', url: 'http://54.204.83.221:8000/')], contextPath: null, war: 'target/*.war'
}
*/

/*
*/

}
83 changes: 83 additions & 0 deletions JenkinsfileDeclarative
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
pipeline{

agent any

tools
{
maven 'maven3.6.3'

}

triggers{
pollSCM('* * * * *')
}

options{
timestamps()
buildDiscarder(logRotator(artifactDaysToKeepStr: '', artifactNumToKeepStr: '2', daysToKeepStr: '', numToKeepStr: '2'))
}

stages{

stage('CheckoutCode')
{
steps{
git branch: 'development', credentialsId: '8e348aa2-9531-4dbe-863d-1adb64897470', url: 'https://github.com/LandmakTechnology/maven-web-application.git'
}
}

stage('Build')
{
steps{
sh "mvn clean package"
}
}

stage('ExecuteSonarQubeReport')
{
steps{
sh "mvn sonar:sonar"
}
}

stage('UploadArtifactintoNexus')
{
steps{
sh "mvn deploy"
}
}

stage('DeployAppIntoTomcat')
{
steps{
sshagent(['2b7b0c6a-5eff-4f4a-82c3-3630f91c70b5']) {
sh "scp -o StrictHostKeyChecking=no target/maven-web-application.war [email protected]:/opt/apache-tomcat-9.0.41/webapps/"
}
}
}



}

post{


success{
mail bcc: '[email protected]', body: '''BuildOver!....

Regards,
Landmark Technologies,
9980923226''', cc: '[email protected]', from: '', replyTo: '', subject: 'BuildOver!!', to: '[email protected]'
}

failure{
mail bcc: '[email protected]', body: '''BuildOver!....

Regards,
Landmark Technologies,
+1 437 215 2483,''', cc: '[email protected]', from: '', replyTo: '', subject: 'BuildOver!!', to: '[email protected]'
}

}
}
51 changes: 51 additions & 0 deletions JenkinsfileJuly2021
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
node('wallmart-node'){

def mavenHome = tool name: "maven3.8.2"

echo "GitHub BranhName ${env.BRANCH_NAME}"
echo "Jenkins Job Number ${env.BUILD_NUMBER}"
echo "Jenkins Node Name ${env.NODE_NAME}"

echo "Jenkins Home ${env.JENKINS_HOME}"
echo "Jenkins URL ${env.JENKINS_URL}"
echo "JOB Name ${env.JOB_NAME}"

stage('CheckOutCode')
{
git branch: 'development', credentialsId: '12993250-1ff3-40a0-9978-794e74dcf712', url: 'https://github.com/LandmakTechnology/maven-web-application.git'
}

stage('Build')
{
sh "${mavenHome}/bin/mvn clean package"
}

/*
stage('SonarQubeReport'){
sh "${mavenHome}/bin/mvn clean sonar:sonar"
}


stage('UploadArtifactIntoNexus'){
sh "${mavenHome}/bin/mvn clean deploy"
}

stage('DeployAppIntoTomcatServer')
{
sshagent(['c7a7b3d8-55f0-4f83-9e81-d56c154cc647']) {
sh "scp -o StrictHostKeyChecking=no target/maven-web-application.war [email protected]:/opt/apache-tomcat-9.0.52/webapps/"
}
}

*/

stage('SendEmailNotification'){
emailext body: '''Build is over !!

Regards,
Landmark Technologies,
9980923226''', subject: 'Build Over... !!', to: '[email protected]'
}


}
60 changes: 60 additions & 0 deletions Jenkinsfile_docker
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
pipeline{
agent any
tools{
maven "maven3.8.4"
}
stages{
stage('GitClone'){
steps{
echo "cloning the lastest applications version"
git "https://github.com/LandmakTechnology/maven-web-application"
}
}
stage('Test+Build'){
steps{
sh "echo Running unitTesting"
sh "mvn clean package"
echo "echo test successful and backupArtifacts created"
}
}
stage('codeQuality'){
steps{
sh "echo Running detail code analysis"
sh "mvn sonar:sonar"
sh "echo All conditions met/passed"
}
}
stage('upLoadArtifacts'){
steps{
sh "echo Running detail code analysis"
sh "mvn deploy"
sh "echo backupArtifacts in nexus"
}
}
stage('predeployment'){
steps{
sh "echo creating docker image"
sh "docker build -t mylandmarktech/maven-web-app . "
sh "docker push mylandmarktech/maven-web-app"
}
}
stage('UnDeploy'){
steps{
sh "echo UNDEPLOYING existing application"
sh "docker rm -f webapp"
}
}
stage('deployment'){
steps{
sh "echo application ready for deployment"
sh "docker run -d -p 8000:8080 --name webapp mylandmarktech/maven-web-app"
}
}
stage('emailNotification'){
steps{
sh "echo deployment successful"
}
}

}
}
77 changes: 77 additions & 0 deletions JenkinsfiledeclarativeJuneBathc
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
pipeline{

agent{
label 'slaves'
}

tools{
maven 'maven3.6.3'

}

triggers{
pollSCM('* * * * *')
}

options{
timestamps()
buildDiscarder(logRotator(artifactDaysToKeepStr: '', artifactNumToKeepStr: '5', daysToKeepStr: '', numToKeepStr: '5'))
}

stages{

stage('CheckOutCode'){
steps{
git branch: 'development', credentialsId: '957b543e-6f77-4cef-9aec-82e9b0230975', url: 'https://github.com/LandmakTechnology/maven-web-application-1.git'

}
}

stage('Build'){
steps{
sh "mvn clean package"
}
}
/*
stage('ExecuteSonarQubeReport'){
steps{
sh "mvn clean sonar:sonar"
}
}

stage('UploadArtifactsIntoNexus'){
steps{
sh "mvn clean deploy"
}
}

stage('DeployAppIntoTomcat'){
steps{
sshagent(['bfe1b3c1-c29b-4a4d-b97a-c068b7748cd0']) {
sh "scp -o StrictHostKeyChecking=no target/maven-web-application.war [email protected]:/opt/apache-tomcat-9.0.50/webapps/"
}
}
}
*/
}//Stages Closing

post{

success{
emailext to: '[email protected],[email protected]',
subject: "Pipeline Build is over .. Build # is ..${env.BUILD_NUMBER} and Build status is.. ${currentBuild.result}.",
body: "Pipeline Build is over .. Build # is ..${env.BUILD_NUMBER} and Build status is.. ${currentBuild.result}.",
replyTo: '[email protected]'
}

failure{
emailext to: '[email protected],[email protected]',
subject: "Pipeline Build is over .. Build # is ..${env.BUILD_NUMBER} and Build status is.. ${currentBuild.result}.",
body: "Pipeline Build is over .. Build # is ..${env.BUILD_NUMBER} and Build status is.. ${currentBuild.result}.",
replyTo: '[email protected]'
}

}


}//Pipeline closing
11 changes: 11 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
version: '3.1'
services:
springboot:
image: mylandmarktech/maven-web-app:VERSION
restart: always
ports:
- 9090:8080
networks:
- mavenappbridge
networks:
mavenappbridge:
10 changes: 5 additions & 5 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@
<spring.version>5.1.2.RELEASE</spring.version>
<junit.version>4.11</junit.version>
<log4j.version>1.2.17</log4j.version>
<sonar.host.url>http:3.238.135.186:9000/</sonar.host.url>
<sonar.login>admin</sonar.login>
<sonar.password>admin</sonar.password>
<sonar.host.url>http://3.96.67.73:7000/</sonar.host.url>
<sonar.login>admin123</sonar.login>
<sonar.password>admin123</sonar.password>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>

Expand Down Expand Up @@ -101,13 +101,13 @@
<repository>
<id>nexus</id>
<name>Landmark Technologies Releases Nexus Repository</name>
<url>http://44.192.81.238:8888/mylandmarktech/repository/boa-release/</url>
<url> http://172.31.18.29:8081/repository/ebay-bts-releases/</url>
</repository>

<snapshotRepository>
<id>nexus</id>
<name>Landmark Technologies Snapshot Nexus Repository </name>
<url>http://44.192.81.238:8888/mylandmarktech/repository/boa-snapshot/</url>
<url>http://100.24.52.91:4000/repository/ebay-bts-snapshot/</url>
</snapshotRepository>

</distributionManagement>
Expand Down
Loading