You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openwhisk.apache.org by md...@apache.org on 2018/03/09 01:41:53 UTC

[incubator-openwhisk-cli] branch master updated: Addition HTTP Headers (#238)

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

mdeuser pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-openwhisk-cli.git


The following commit(s) were added to refs/heads/master by this push:
     new ff385df  Addition HTTP Headers (#238)
ff385df is described below

commit ff385dfc21df006078a818b13aec04750183b32e
Author: James Dubee <jw...@us.ibm.com>
AuthorDate: Thu Mar 8 20:41:51 2018 -0500

    Addition HTTP Headers (#238)
    
    * Addition HTTP Headers
    
    * Use http.Header as AdditionalHeader type
---
 build.gradle         |  2 +-
 commands/commands.go | 20 +++++++++++---------
 2 files changed, 12 insertions(+), 10 deletions(-)

diff --git a/build.gradle b/build.gradle
index c596134..2f46836 100644
--- a/build.gradle
+++ b/build.gradle
@@ -24,7 +24,7 @@ dependencies {
         build(['name':'golang.org/x/sys/unix', 'version':'7f918dd405547ecb864d14a8ecbbfe205b5f930f', 'transitive':false])
         build(['name':'gopkg.in/yaml.v2', 'version':'cd8b52f8269e0feb286dfeef29f8fe4d5b397e0b', 'transitive':false])
         build(['name':'github.com/ghodss/yaml', 'version':'0ca9ea5df5451ffdf184b4428c902747c2c11cd7', 'transitive':false])
-        build(['name':'github.com/apache/incubator-openwhisk-client-go/whisk','version':'025300c38d0b790d161d3776d84e1da340e2b202','transitive':false])
+        build(['name':'github.com/apache/incubator-openwhisk-client-go/whisk','version':'012fd0fb022fd542fdd7606567d0c9b38ca56bd8','transitive':false])
         // END - Imported from Godeps
         test name:'github.com/stretchr/testify', version:'b91bfb9ebec76498946beb6af7c0230c7cc7ba6c', transitive:false //, tag: 'v1.2.0'
         test name:'github.com/spf13/viper', version:'aafc9e6bc7b7bb53ddaa75a5ef49a17d6e654be5', transitive:false
diff --git a/commands/commands.go b/commands/commands.go
index 2fbdeb1..0e5f115 100644
--- a/commands/commands.go
+++ b/commands/commands.go
@@ -33,6 +33,7 @@ var Client *whisk.Client
 const DefaultOpenWhiskApiPath string = "/api"
 
 var UserAgent string = "OpenWhisk-CLI"
+var AdditionalHeaders http.Header
 
 func SetupClientConfig(cmd *cobra.Command, args []string) error {
 	baseURL, err := whisk.GetURLBase(Properties.APIHost, DefaultOpenWhiskApiPath)
@@ -55,15 +56,16 @@ func SetupClientConfig(cmd *cobra.Command, args []string) error {
 	}
 
 	clientConfig := &whisk.Config{
-		Cert:      Properties.Cert,
-		Key:       Properties.Key,
-		AuthToken: Properties.Auth,
-		Namespace: Properties.Namespace,
-		BaseURL:   baseURL,
-		Version:   Properties.APIVersion,
-		Insecure:  Flags.Global.Insecure,
-		Host:      Properties.APIHost,
-		UserAgent: UserAgent + "/1.0 (" + Properties.CLIVersion + ")",
+		Cert:              Properties.Cert,
+		Key:               Properties.Key,
+		AuthToken:         Properties.Auth,
+		Namespace:         Properties.Namespace,
+		BaseURL:           baseURL,
+		Version:           Properties.APIVersion,
+		Insecure:          Flags.Global.Insecure,
+		Host:              Properties.APIHost,
+		UserAgent:         UserAgent + "/1.0 (" + Properties.CLIVersion + ")",
+		AdditionalHeaders: AdditionalHeaders,
 	}
 
 	if len(clientConfig.Host) == 0 {

-- 
To stop receiving notification emails like this one, please contact
mdeuser@apache.org.