mirror of
https://github.com/spring-projects/spring-petclinic.git
synced 2025-07-18 05:25:50 +00:00
Update Jenkinsfile
This commit is contained in:
parent
5be1106f60
commit
7ad54503b9
1 changed files with 4 additions and 4 deletions
8
Jenkinsfile
vendored
8
Jenkinsfile
vendored
|
@ -47,8 +47,8 @@ pipeline {
|
||||||
script {
|
script {
|
||||||
def shortCommit = sh(script: "git rev-parse --short HEAD", returnStdout: true).trim()
|
def shortCommit = sh(script: "git rev-parse --short HEAD", returnStdout: true).trim()
|
||||||
|
|
||||||
docker.withRegistry("http://${env.NEXUS_SERVER}:${env.NEXUS_PORT_MR}", 'nexus-credentials') {
|
docker.withRegistry("http://host.docker.internal:${env.NEXUS_PORT_MR}", 'nexus-credentials') {
|
||||||
def customImage = docker.build("${env.NEXUS_SERVER}:${env.NEXUS_PORT_MR}/${env.NEXUS_REPO_MR}:${shortCommit}", "-f Dockerfile.multi .")
|
def customImage = docker.build("host.docker.internal:${env.NEXUS_PORT_MR}/${env.NEXUS_REPO_MR}:${shortCommit}", "-f Dockerfile.multi .")
|
||||||
customImage.push()
|
customImage.push()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -78,8 +78,8 @@ pipeline {
|
||||||
script {
|
script {
|
||||||
def shortCommit = sh(script: "git rev-parse --short HEAD", returnStdout: true).trim()
|
def shortCommit = sh(script: "git rev-parse --short HEAD", returnStdout: true).trim()
|
||||||
|
|
||||||
docker.withRegistry("http://${env.NEXUS_SERVER}:${env.NEXUS_PORT_MAIN}", 'nexus-credentials') {
|
docker.withRegistry("http://host.docker.internal:${env.NEXUS_PORT_MAIN}", 'nexus-credentials') {
|
||||||
def customImage = docker.build("${env.NEXUS_SERVER}:${env.NEXUS_PORT_MAIN}/${env.NEXUS_REPO_MAIN}:${shortCommit}", "-f Dockerfile.multi .")
|
def customImage = docker.build("host.docker.internal:${env.NEXUS_PORT_MAIN}/${env.NEXUS_REPO_MAIN}:${shortCommit}", "-f Dockerfile.multi .")
|
||||||
customImage.push()
|
customImage.push()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue