From 7863fc7f8abe5a14ae6f290aaa12cbac645f8e02 Mon Sep 17 00:00:00 2001 From: wanyaoqi Date: Mon, 24 Feb 2020 16:36:44 +0800 Subject: [PATCH] fix host register get network filter: add server_type baremetal --- pkg/hostman/hostinfo/hostinfo.go | 1 + 1 file changed, 1 insertion(+) diff --git a/pkg/hostman/hostinfo/hostinfo.go b/pkg/hostman/hostinfo/hostinfo.go index 7f41393d4b..a6fba6ba74 100644 --- a/pkg/hostman/hostinfo/hostinfo.go +++ b/pkg/hostman/hostinfo/hostinfo.go @@ -705,6 +705,7 @@ func (h *SHostInfo) fetchAccessNetworkInfo() { params := jsonutils.NewDict() params.Set("ip", jsonutils.NewString(masterIp)) params.Set("is_on_premise", jsonutils.JSONTrue) + params.Set("server_type", jsonutils.NewString(api.NETWORK_TYPE_BAREMETAL)) params.Set("limit", jsonutils.NewInt(0)) res, err := modules.Networks.List(h.GetSession(), params)