Skip to content
This repository has been archived by the owner on Jan 25, 2023. It is now read-only.

Commit

Permalink
Dump more env and fix tag reference env var
Browse files Browse the repository at this point in the history
  • Loading branch information
bcomnes committed Dec 8, 2018
1 parent 924b079 commit bb7ccf8
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ pipeline {
not { buildingTag() }
}
steps {
sh "env"
sh "docker build --build-arg NF_IMAGE_VERSION=${env.GIT_COMMIT} -t netlify/build:${env.BRANCH_NAME} -t netlify/build:${env.GIT_COMMIT} ."
sh "docker build --build-arg NF_IMAGE_VERSION=${env.GIT_COMMIT} --squash -t netlify/build:${env.BRANCH_NAME}-squash -t netlify/build:${env.GIT_COMMIT}-squash ."
}
Expand All @@ -28,8 +29,8 @@ pipeline {
}
steps {
sh "env"
sh "docker build --build-arg NF_IMAGE_VERSION=${env.GIT_COMMIT} -t netlify/build:${env.GIT_TAG_NAME} -t netlify/build:${env.GIT_COMMIT} ."
sh "docker build --build-arg NF_IMAGE_VERSION=${env.GIT_COMMIT} --squash -t netlify/build:${env.GIT_TAG_NAME}-squash -t netlify/build:${env.GIT_COMMIT}-squash ."
sh "docker build --build-arg NF_IMAGE_VERSION=${env.GIT_COMMIT} -t netlify/build:${env.GIT_BRANCH} -t netlify/build:${env.GIT_COMMIT} ."
sh "docker build --build-arg NF_IMAGE_VERSION=${env.GIT_COMMIT} --squash -t netlify/build:${env.GIT_BRANCH}-squash -t netlify/build:${env.GIT_COMMIT}-squash ."
}
}

Expand All @@ -40,9 +41,9 @@ pipeline {
steps {
script {
docker.withRegistry('https://index.docker.io/v1/', 'docker-hub-ci') {
docker.image("netlify/build:${env.GIT_TAG_NAME}").push()
docker.image("netlify/build:${env.GIT_BRANCH}").push()
docker.image("netlify/build:${env.GIT_COMMIT}").push()
docker.image("netlify/build:${env.GIT_TAG_NAME}-squash").push()
docker.image("netlify/build:${env.GIT_BRANCH}-squash").push()
docker.image("netlify/build:${env.GIT_COMMIT}-squash").push()
}
}
Expand Down

0 comments on commit bb7ccf8

Please sign in to comment.