diff --git a/Dockerfile b/Dockerfile index 14a2807e..ab6905ac 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,2 +1,2 @@ FROM tomcat:8.0.20-jre8 -COPY target/*.war /usr/local/tomcat/webapps/td.war +COPY target/*.war /usr/local/tomcat/webapps/cohort7.war diff --git a/jenkinsfileNnenna b/jenkinsfileNnenna new file mode 100644 index 00000000..4cbe0f48 --- /dev/null +++ b/jenkinsfileNnenna @@ -0,0 +1,45 @@ +pipeline{ + agent any + tools{ + maven "maven3.8.6" + } + stages{ + stage("1.CodeClone"){ + steps{ + git credentialsId: 'Github-Cred2', url: 'https://github.com/Nubanwani6/web-app.git' + } + } + stage("2.Build"){ + steps{ + sh "mvn clean package" + } + } + stage("3.Artifacts"){ + steps{ + sh "mvn deploy" + } + } + stage("4.DeploytoUAT"){ + steps{ + deploy adapters: [tomcat9(credentialsId: 'tomcat-cred', path: '', url: 'http://54.184.138.80:8080/')], contextPath: null, war: 'target/*.war' + } + } + stage("5.Approval"){ + steps{ + timeout(time:5, unit:'DAYS'){ + input message: 'Approval for Production' + } + } + } + stage("6.DeploytoPROD"){ + steps{ + deploy adapters: [tomcat9(credentialsId: 'tomcat-cred', path: '', url: 'http://54.184.138.80:8080/')], contextPath: null, war: 'target/*.war' + } + } + stage("7.EmailNotification"){ + steps{ + emailext body: 'This is Build Success', subject: 'Build Success', to: 'info@acadalearning.com' + } + } + } +} diff --git a/pom.xml b/pom.xml index 3669c1ce..0b7dabbe 100644 --- a/pom.xml +++ b/pom.xml @@ -5,7 +5,7 @@ com.mt maven-web-application war - 2.0.1-RELEASE + 2.0.3-SNAPSHOT maven-web-application @@ -21,7 +21,7 @@ 5.1.2.RELEASE 4.11 1.2.17 - http://50.19.176.11:5000/ + http://172.31.15.25:5000/ admin admin123 UTF-8 @@ -97,13 +97,13 @@ nexus ACADA Learning Releases Nexus Repository - http://172.31.94.25:8081/repository/UBA-release/ + http://http://172.31.10.202:8081/repository/td-app-release/ nexus ACADA Learning Snapshot Nexus Repository - http://172.31.94.25:8081/repository/UBA-Snapshot/ + http://172.31.10.202:8081/repository/td-app-snapshot/