diff --git a/Jenkinsfile b/Jenkinsfile index 73a4c60e7..ed132bf14 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -94,11 +94,11 @@ pipeline { CREDENTIALS = credentials('docker-registry') IMAGE = "$REGISTRY/verdnatura/salix-back" } - script { - def packageJson = readJSON file: 'package.json' - env.VERSION = "${packageJson.version}-build${env.BUILD_ID}" - } steps { + script { + def packageJson = readJSON file: 'package.json' + env.VERSION = "${packageJson.version}-build${env.BUILD_ID}" + } sh 'docker-compose build back' sh 'docker login --username $CREDENTIALS_USR --password $CREDENTIALS_PSW $REGISTRY' sh 'docker push $IMAGE:$BRANCH_NAME'