Skip to content

Commit 0197ba6

Browse files
Working on Jenkinsfile for Docker
1 parent 3ec680e commit 0197ba6

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

JenkinsFileDocker

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ pipeline
3434
{
3535
steps()
3636
{
37-
sh 'docker build -t mithuntechnologies/logindockerjenkins:${buildNumber} .'
37+
sh 'docker build -t mithuntechnologies/maven-web-application:${buildNumber} .'
3838
}
3939
}
4040

@@ -46,15 +46,15 @@ pipeline
4646
{
4747
sh 'docker login -u mithuntechnologies -p ${Docker_Hub_Password}'
4848
}
49-
sh 'docker push mithuntechnologies/logindockerjenkins:${buildNumber}'
49+
sh 'docker push mithuntechnologies/maven-web-application:${buildNumber}'
5050
}
5151
}
5252

5353
stage('Remove Docker Image from Jenkins Locally')
5454
{
5555
steps()
5656
{
57-
sh 'docker rmi -f mithuntechnologies/logindockerjenkins:${buildNumber}'
57+
sh 'docker rmi -f mithuntechnologies/maven-web-application:${buildNumber}'
5858
}
5959
}
6060

@@ -65,7 +65,7 @@ pipeline
6565
sshagent(['DeploymentServer_SSH'])
6666
{
6767
sh "ssh -o StrictHostKeyChecking=no [email protected] docker rm -f mavenwebapplication || true"
68-
sh "ssh -o StrictHostKeyChecking=no [email protected] docker run -d --name mavenwebapplication -p 8080:8080 mithuntechnologies/logindockerjenkins:$Build_Number"
68+
sh "ssh -o StrictHostKeyChecking=no [email protected] docker run -d --name mavenwebapplication -p 8080:8080 mithuntechnologies/maven-web-application:$Build_Number"
6969
}
7070
}
7171
}

0 commit comments

Comments
 (0)