mirror of
https://github.com/spring-projects/spring-petclinic.git
synced 2025-07-27 09:25:49 +00:00
another fix
This commit is contained in:
parent
c114ec8432
commit
0c1ab03281
2 changed files with 18 additions and 1 deletions
|
@ -1,3 +1,4 @@
|
|||
FROM openjdk:8-jdk-alpine
|
||||
WORKDIR /build
|
||||
CMD [ "./build.sh" ]
|
||||
COPY build.sh .
|
||||
|
|
18
Jenkinsfile
vendored
18
Jenkinsfile
vendored
|
@ -14,11 +14,27 @@ pipeline {
|
|||
}
|
||||
steps {
|
||||
script {
|
||||
sh 'docker cp petclinic-build:/build/target/app.jar .'
|
||||
echo 'Done'
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
stage('Copy .jar file') {
|
||||
agent {
|
||||
docker {
|
||||
image 'docker:dind'
|
||||
additionalBuildArgs '-t petclinic-build'
|
||||
args '-v /var/run/docker.sock:/var/run/docker.sock'
|
||||
}
|
||||
}
|
||||
steps {
|
||||
sh """docker run -d --rm \
|
||||
-v /var/run/docker.sock:/var/run/docker.sock \
|
||||
--name petclinic-build
|
||||
petclinic-build"""
|
||||
}
|
||||
}
|
||||
|
||||
stage('Run') {
|
||||
agent {
|
||||
dockerfile {
|
||||
|
|
Loading…
Reference in a new issue