You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@openwhisk.apache.org by GitBox <gi...@apache.org> on 2018/11/16 19:57:14 UTC

[GitHub] csantanapr closed pull request #361: Also tag with githash when tagging with latest

csantanapr closed pull request #361: Also tag with githash when tagging with latest
URL: https://github.com/apache/incubator-openwhisk-deploy-kube/pull/361
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/tools/travis/publish.sh b/tools/travis/publish.sh
index baa6362..709d066 100755
--- a/tools/travis/publish.sh
+++ b/tools/travis/publish.sh
@@ -13,3 +13,10 @@ dockerhub_image="${dockerhub_image_prefix}/${dockerhub_image_name}:${dockerhub_i
 docker login -u "${DOCKER_USER}" -p "${DOCKER_PASSWORD}"
 docker build ${dir_to_build} --tag ${dockerhub_image}
 docker push ${dockerhub_image}
+
+if [ ${dockerhub_image_tag} == "latest" ]; then
+    short_commit=`git rev-parse --short HEAD`
+    dockerhub_image_alias="${dockerhub_image_prefix}/${dockerhub_image_name}:${short_commit}"
+    docker tag ${dockerhub_image} ${dockerhub_image_alias}
+    docker push ${dockerhub_image_alias}
+fi


 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services