Skip to content

Commit

Permalink
Change to use dockerhub env vars
Browse files Browse the repository at this point in the history
  • Loading branch information
sychan committed Oct 26, 2018
1 parent e0f8bde commit 6aec33d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions hooks/build
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ echo "Build hook running"
echo "IMAGE_NAME = ${IMAGE_NAME}"
echo "DOCKER_REPO = ${DOCKER_REPO}"
echo "CACHE_TAG = ${CACHE_TAG}"
export BRANCH=${TRAVIS_BRANCH:-`git symbolic-ref --short HEAD`}
export BRANCH=${SOURCE_BRANCH:-`git symbolic-ref --short HEAD`}

export DATE=`date -u +"%Y-%m-%dT%H:%M:%SZ"`
export COMMIT=${TRAVIS_COMMIT:-`git rev-parse --short HEAD`}
export COMMIT=${SOURCE_COMMIT:-`git rev-parse --short HEAD`}
docker build --build-arg BUILD_DATE=$DATE \
--build-arg VCS_REF=$COMMIT \
--build-arg BRANCH=$BRANCH \
Expand Down

0 comments on commit 6aec33d

Please sign in to comment.