add openpitrix proxy token

This commit is contained in:
hongming
2018-10-09 19:55:45 +08:00
parent adc77fcd58
commit 85b3da3dcd
2 changed files with 17 additions and 0 deletions

View File

@@ -28,6 +28,8 @@ import (
"github.com/golang/glog"
"github.com/jinzhu/gorm"
"github.com/pkg/errors"
"kubesphere.io/kubesphere/pkg/constants"
)
const (
@@ -78,6 +80,8 @@ func makeHttpRequest(method, url, data string) ([]byte, error) {
req, err = http.NewRequest(method, url, strings.NewReader(data))
}
req.Header.Add("Authorization", constants.OpenPitrixProxyToken)
if err != nil {
glog.Error(err)
return nil, err