Browse Source

config template&k8s ns

Signed-off-by: zhouqunjie <450705171@qq.com>
pull/9/head
zhouqunjie 3 years ago
parent
commit
55abc4c9df
2 changed files with 6 additions and 2 deletions
  1. +2
    -2
      adaptor/pod_adaptor/server/pod/pod.go
  2. +4
    -0
      configs/config_template.yaml

+ 2
- 2
adaptor/pod_adaptor/server/pod/pod.go View File

@@ -230,9 +230,9 @@ func ListPodAll(ctx context.Context) (*pbpod.ListPodResp, error) {
go func(provider int32) {
defer wg.Done()

//针对私有K8S集群,调用listAll时默认只查询default namespace下的pod
//针对私有K8S集群,调用listAll时默认只查询ListPodDetailReq namespace下的pod
if provider == 3 {
resp, err := ListPod(ctx, &pbpod.ListPodReq{Provider: pbtenant.CloudProvider(provider), Namespace: "default"})
resp, err := ListPod(ctx, &pbpod.ListPodReq{Provider: pbtenant.CloudProvider(provider), Namespace: "pcm"})
if err != nil {
glog.Errorf("List error %v", err)
return


+ 4
- 0
configs/config_template.yaml View File

@@ -12,3 +12,7 @@ configs:
name: "huawei-PCM"
accessid: ""
accesssecret: ""
- provider: 3
name: "K8S-PCM"
url: ""
token: ""

Loading…
Cancel
Save