You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openwhisk.apache.org by dg...@apache.org on 2021/10/08 23:57:41 UTC

[openwhisk] branch asf-jenkins-test updated (582b424 -> 5cc1259)

This is an automated email from the ASF dual-hosted git repository.

dgrove pushed a change to branch asf-jenkins-test
in repository https://gitbox.apache.org/repos/asf/openwhisk.git.


 discard 582b424  take 2
 discard 6bbdde3  experiment with docker login to local dir
     new 5cc1259  docker creds in build-specific directory

This update added new revisions after undoing existing revisions.
That is to say, some revisions that were in the old version of the
branch are not in the new version.  This situation occurs
when a user --force pushes a change and generates a repository
containing something like this:

 * -- * -- B -- O -- O -- O   (582b424)
            \
             N -- N -- N   refs/heads/asf-jenkins-test (5cc1259)

You should already have received notification emails for all of the O
revisions, and so the following emails describe only the N revisions
from the common base, B.

Any revisions marked "omit" are not gone; other references still
refer to them.  Any revisions marked "discard" are gone forever.

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:

[openwhisk] 01/01: docker creds in build-specific directory

Posted by dg...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

dgrove pushed a commit to branch asf-jenkins-test
in repository https://gitbox.apache.org/repos/asf/openwhisk.git

commit 5cc1259dddc7852e7cf16cfbfcf3a823a1c5b41b
Author: David Grove <gr...@us.ibm.com>
AuthorDate: Fri Oct 8 18:30:23 2021 -0400

    docker creds in build-specific directory
---
 tools/jenkins/apache/dockerhub.groovy | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/tools/jenkins/apache/dockerhub.groovy b/tools/jenkins/apache/dockerhub.groovy
index c1b7c25..6ff1c59 100644
--- a/tools/jenkins/apache/dockerhub.groovy
+++ b/tools/jenkins/apache/dockerhub.groovy
@@ -26,15 +26,16 @@ node('ubuntu') {
   stage("Build and Deploy to DockerHub") {
     def JAVA_JDK_8=tool name: 'jdk_1.8_latest', type: 'hudson.model.JDK'
     withEnv(["Path+JDK=$JAVA_JDK_8/bin","JAVA_HOME=$JAVA_JDK_8"]) {
+      sh "mkdir $WORKSPACE/local-docker-cfg"
       withCredentials([usernamePassword(credentialsId: 'openwhisk_dockerhub', passwordVariable: 'DOCKER_PASSWORD', usernameVariable: 'DOCKER_USER')]) {
-          sh 'docker login -u ${DOCKER_USER} -p ${DOCKER_PASSWORD}'
+          sh 'HOME="$WORKSPACE/local-docker-cfg" docker login -u ${DOCKER_USER} -p ${DOCKER_PASSWORD}'
       }
       def PUSH_CMD = "./gradlew :core:controller:distDocker :core:invoker:distDocker :core:standalone:distDocker :core:monitoring:user-events:distDocker :tools:ow-utils:distDocker :core:cosmos:cache-invalidator:distDocker -PdockerRegistry=docker.io -PdockerImagePrefix=openwhisk"
       def gitCommit = sh(returnStdout: true, script: 'git rev-parse HEAD').trim()
       def shortCommit = gitCommit.take(7)
       sh "./gradlew clean"
-      sh "${PUSH_CMD} -PdockerImageTag=nightly"
-      sh "${PUSH_CMD} -PdockerImageTag=${shortCommit}"
+      sh "HOME=\"$WORKSPACE/local-docker-cfg\" ${PUSH_CMD} -PdockerImageTag=nightly"
+      sh "HOME=\"$WORKSPACE/local-docker-cfg\" ${PUSH_CMD} -PdockerImageTag=${shortCommit}"
     }
   }
 
@@ -42,6 +43,8 @@ node('ubuntu') {
     sh "docker images"
     sh 'docker rmi -f $(docker images -f "reference=openwhisk/*" -q) || true'
     sh "docker images"
+    sh "docker logout"
+    sh "rm -rf $WORKSPACE/local-docker-cfg"
   }
 
   stage("Notify") {