Владимир Томишинец 5 years ago
parent
commit
6d39f8a3a0
1 changed files with 1 additions and 1 deletions
  1. 1 1
      Jenkinsfile-dev

+ 1 - 1
Jenkinsfile-dev

@@ -46,7 +46,7 @@ pipeline {
         }
         sh "docker build --build-arg branch=${branch} --no-cache -t ${DOCKER_REGISTRY}/${DOCKER_IMAGE}:${BUILD_NUMBER} ."
         script {
-           NEWTAG = sh script: "docker run --rm ${DOCKER_REGISTRY}/${DOCKER_IMAGE}:${BUILD_NUMBER} cat /tmp/version 2> /dev/null", returnStdout: true
+           NEWTAG = sh(script: "docker run --rm ${DOCKER_REGISTRY}/${DOCKER_IMAGE}:${BUILD_NUMBER} cat /tmp/version 2> /dev/null", returnStdout: true).trim()
            NEWTAG = branch + "-" + NEWTAG + "_" + BUILD_NUMBER
            echo "NEWTAG is $NEWTAG"
         }