feat: refs #6695 try up db
gitea/salix/pipeline/pr-dev This commit looks good Details

This commit is contained in:
Alex Moreno 2024-09-25 14:17:01 +02:00
parent c2598b9e80
commit 85a804001f
1 changed files with 21 additions and 21 deletions

42
Jenkinsfile vendored
View File

@ -186,27 +186,27 @@ pipeline {
}
}
}
// stage('Push') {
// when {
// expression { RUN_BUILD }
// }
// environment {
// CREDENTIALS = credentials('docker-registry')
// }
// steps {
// script {
// def packageJson = readJSON file: 'package.json'
// env.VERSION = "${packageJson.version}-build${env.BUILD_ID}"
// }
// 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('Push') {
when {
expression { RUN_BUILD }
}
environment {
CREDENTIALS = credentials('docker-registry')
}
steps {
script {
def packageJson = readJSON file: 'package.json'
env.VERSION = "${packageJson.version}-build${env.BUILD_ID}"
}
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 {