From 9a40c2c09c5cc789c00333d5181a1d7449a5c6f2 Mon Sep 17 00:00:00 2001 From: JustFiesta Date: Mon, 29 Apr 2024 18:34:42 +0200 Subject: [PATCH] Add build docker image step in Jenkinsfile --- Jenkinsfile | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/Jenkinsfile b/Jenkinsfile index 219cf37a6..f18f03b40 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -25,5 +25,13 @@ pipeline { archiveArtifacts artifacts: 'build/libs/*.jar' } } + stage('Docker Build') { + + steps { + echo 'Building docker Image' + sh 'docker build -t $NEXUS_DOCKER_REPO/spring-petclinic:${GIT_COMMIT} .' + } + } + } } \ No newline at end of file