mirror of
https://github.com/spring-projects/spring-petclinic.git
synced 2025-07-20 14:55:50 +00:00
Edit Jenkinsfile
This commit is contained in:
parent
755b8b319a
commit
bf22d5a432
1 changed files with 11 additions and 0 deletions
11
Jenkinsfile
vendored
11
Jenkinsfile
vendored
|
@ -1,5 +1,10 @@
|
||||||
pipeline {
|
pipeline {
|
||||||
agent any
|
agent any
|
||||||
|
|
||||||
|
environment {
|
||||||
|
GIT_COMMIT = sh(script: 'git rev-parse --short HEAD', returnStdout: true).trim()
|
||||||
|
}
|
||||||
|
|
||||||
stages {
|
stages {
|
||||||
stage ('Checkstyle') {
|
stage ('Checkstyle') {
|
||||||
steps {
|
steps {
|
||||||
|
@ -18,5 +23,11 @@ pipeline {
|
||||||
archiveArtifacts artifacts: 'target/*.jar', allowEmptyArchive: false
|
archiveArtifacts artifacts: 'target/*.jar', allowEmptyArchive: false
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
stage ('Creating Docker image') {
|
||||||
|
steps {
|
||||||
|
sh 'docker build -t vkarpenko02/spring-petclinic:${GIT_COMMIT} .'
|
||||||
|
sh 'docker push vkarpenko02/mr'
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
Loading…
Reference in a new issue