Skip to content

Commit

Permalink
fully tagging the images
Browse files Browse the repository at this point in the history
  • Loading branch information
John Gasper committed Sep 5, 2018
1 parent 1804879 commit 455fb29
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -69,8 +69,8 @@ pipeline {
stage('Build Base') {
steps {
script {
docker.withRegistry('https://registry.hub.docker.com/', "dockerhub-$maintainer") {
def baseImg = docker.build("$maintainer/$imagename", "--no-cache --pull base")
docker.withRegistry('https://registry.hub.docker.com/', "dockerhub-${maintainer}") {
def baseImg = docker.build("${maintainer}/${imagename}:base", "--no-cache --pull base")
baseImg.push("base")
}
}
Expand All @@ -79,7 +79,7 @@ pipeline {
stage('Build Others') {
steps {
script {
docker.withRegistry('https://registry.hub.docker.com/', "dockerhub-$maintainer") {
docker.withRegistry('https://registry.hub.docker.com/', "dockerhub-${maintainer}") {
def tagSet = generateTagSet()
def builds = build(tagSet)

Expand All @@ -97,7 +97,7 @@ pipeline {
stage('Notify') {
steps{
echo "$maintainer"
slackSend color: 'good', message: "$maintainer/$imagename set pushed to DockerHub"
slackSend color: 'good', message: "${maintainer}/${imagename} set pushed to DockerHub"
}
}
}
Expand Down Expand Up @@ -143,7 +143,7 @@ def build(tagSet) {
def builds = [:]

for (String tag : tagSet) {
def baseImg = docker.build("$maintainer/$imagename", "--no-cache $tag")
def baseImg = docker.build("${maintainer}/${imagename}:${tag}", "--no-cache ${tag}")
echo "built ${tag}; adding to the push queue"
builds.put(tag, baseImg);
}
Expand Down

0 comments on commit 455fb29

Please sign in to comment.