mirror of
https://github.com/spring-projects/spring-petclinic.git
synced 2025-07-21 23:35:50 +00:00
Update Jenkinsfile
This commit is contained in:
parent
48ec6fbe36
commit
d470462bb3
1 changed files with 4 additions and 4 deletions
6
Jenkinsfile
vendored
6
Jenkinsfile
vendored
|
@ -60,20 +60,20 @@ pipeline {
|
||||||
script {
|
script {
|
||||||
sh 'rm -f ~/.dockercfg ~/.docker/config.json || true'
|
sh 'rm -f ~/.dockercfg ~/.docker/config.json || true'
|
||||||
docker.withRegistry("http://${ECR_REPOSITORY}", "ecr:${REGION}:${AWS_CREDENTIAL_NAME}") {
|
docker.withRegistry("http://${ECR_REPOSITORY}", "ecr:${REGION}:${AWS_CREDENTIAL_NAME}") {
|
||||||
docker.image("{ECR_DOCKER_IMAGE}:${BUILD_NUMBER}").push()
|
docker.image("${ECR_DOCKER_IMAGE}:${BUILD_NUMBER}").push()
|
||||||
docker.image("${ECR_DOCKER_IMAGE}:latest").push()
|
docker.image("${ECR_DOCKER_IMAGE}:latest").push()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/*
|
|
||||||
stage('Clean Up Docker Images on Jenkins Server'){
|
stage('Clean Up Docker Images on Jenkins Server'){
|
||||||
steps {
|
steps {
|
||||||
echo 'Cleaning up unused Docker images on Jenkins server'
|
echo 'Cleaning up unused Docker images on Jenkins server'
|
||||||
sh "docker image prune -f --all --filter \"until=1h\""
|
sh "docker image prune -f --all --filter \"until=1h\""
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
*/
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue