Skip to content

Commit

Permalink
Update Jenkinsfile
Browse files Browse the repository at this point in the history
  • Loading branch information
chubing authored Sep 30, 2023
1 parent 08858bb commit 39bba86
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -89,10 +89,10 @@ pipeline {
sh 'docker login -u tieradmin -p $DOCKERHUBPW'
sh 'docker buildx inspect --bootstrap'
sh 'docker buildx ls'
sh "docker buildx build --platform linux/amd64 -t ${imagename} --build-arg VERSION_TAG=${tag} --load ${folder}"
sh "docker buildx build --platform linux/arm64 -t ${imagename}:arm64 --build-arg VERSION_TAG=${tag} --load ${folder}"
echo "Pushing image to dockerhub..."
sh "docker buildx build --push --platform linux/arm64,linux/amd64 -t ${maintainer}/${imagename}:${exercise}-${tag} ${folder}"
//sh "docker buildx build --platform linux/amd64 -t ${imagename} --build-arg VERSION_TAG=${tag} --load ${folder}"
//sh "docker buildx build --platform linux/arm64 -t ${imagename}:arm64 --build-arg VERSION_TAG=${tag} --load ${folder}"
echo "Pushing image ${maintainer}/${imagename}:${exercise}-${tag} to dockerhub..."
sh "docker buildx build --push --platform linux/arm64,linux/amd64 -t ${maintainer}/${imagename}:${exercise}-${tag} --build-arg VERSION_TAG=${tag} ${folder}"
}
} else {
echo "not building images, since the SCM branch is not ${TARGET_BRANCH}"
Expand Down

0 comments on commit 39bba86

Please sign in to comment.