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 2017/12/19 03:42:00 UTC

[GitHub] rabbah closed pull request #3112: optional bypass of whisk.properties when setting GW_ values

rabbah closed pull request #3112: optional bypass of whisk.properties when setting GW_ values
URL: https://github.com/apache/incubator-openwhisk/pull/3112
 
 
   

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/ansible/roles/routemgmt/files/installRouteMgmt.sh b/ansible/roles/routemgmt/files/installRouteMgmt.sh
index bf805cebb4..73a497e146 100755
--- a/ansible/roles/routemgmt/files/installRouteMgmt.sh
+++ b/ansible/roles/routemgmt/files/installRouteMgmt.sh
@@ -22,9 +22,15 @@ NAMESPACE="$3"
 WSK_CLI="$4"
 
 WHISKPROPS_FILE="$OPENWHISK_HOME/whisk.properties"
-GW_USER=`fgrep apigw.auth.user= $WHISKPROPS_FILE | cut -d'=' -f2`
-GW_PWD=`fgrep apigw.auth.pwd= $WHISKPROPS_FILE | cut -d'=' -f2-`
-GW_HOST_V2=`fgrep apigw.host.v2= $WHISKPROPS_FILE | cut -d'=' -f2`
+if [ -z "$GW_USER" ]; then
+   GW_USER=`fgrep apigw.auth.user= $WHISKPROPS_FILE | cut -d'=' -f2`
+fi
+if [ -z "$GW_PWD" ]; then
+    GW_PWD=`fgrep apigw.auth.pwd= $WHISKPROPS_FILE | cut -d'=' -f2-`
+fi
+if [ -z "$GW_HOST_V2" ]; then
+    GW_HOST_V2=`fgrep apigw.host.v2= $WHISKPROPS_FILE | cut -d'=' -f2`
+fi
 
 # If the auth key file exists, read the key in the file. Otherwise, take the
 # first argument as the key itself.


 

----------------------------------------------------------------
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