Added latest tag for master branch

This commit is contained in:
Parra 2022-02-27 19:11:40 +01:00
parent d93c0dd9c5
commit a71b7ef8e7
1 changed files with 2 additions and 2 deletions

4
Jenkinsfile vendored
View File

@ -17,7 +17,7 @@ pipeline {
if (env.BRANCH_NAME.startsWith('release/')) {
VERSION = (env.BRANCH_NAME).tokenize('/')[1]
} else if (env.BRANCH_NAME.equals('master')) {
VERSION = ''
VERSION = 'latest'
} else {
VERSION = 'unstable'
}
@ -59,7 +59,7 @@ pipeline {
}
echo "Building ${TARGET_IMAGE} image..."
sh "docker pull ${SOURCE_IMAGE}"
sh "docker buildx build -t ${TARGET_IMAGE} --platform ${PLATFORM} --build-arg VERSION=${PLATFORM.tokenize('/')[1]} ."
sh "docker buildx build -t ${TARGET_IMAGE} --platform ${PLATFORM} --build-arg VERSION=${VERSION} ."
}
}
}