fix: jenkins script
gitea/salix/pipeline/pr-dev There was a failure building this commit Details

This commit is contained in:
Alex Moreno 2024-07-19 13:15:59 +02:00
parent 23e2c9890f
commit d56c8ee3a9
1 changed files with 5 additions and 3 deletions

2
Jenkinsfile vendored
View File

@ -188,12 +188,14 @@ pipeline {
}
sh 'docker login --username $CREDENTIALS_USR --password $CREDENTIALS_PSW $REGISTRY'
sh 'docker-compose push'
script {
if (env.BRANCH_NAME == 'master') {
sh 'docker tag $IMAGE:$TAG $IMAGE:latest'
sh 'docker push $IMAGE:latest'
}
}
}
}
stage('Deploy') {
when {
expression { PROTECTED_BRANCH }