[ Agent ] [ Initialization ] - add harbor func - 1
This commit is contained in:
@@ -1,6 +1,9 @@
|
||||
package executor
|
||||
|
||||
import "strings"
|
||||
import (
|
||||
"strconv"
|
||||
"strings"
|
||||
)
|
||||
|
||||
func BuildAgentOsOperator(osInfo string, ossOfflinePrefix string) *AgentOsOperator {
|
||||
|
||||
@@ -84,8 +87,6 @@ func detectByOsType(os *AgentOsOperator, osInfo string) {
|
||||
|
||||
func detectByInternet(os *AgentOsOperator) {
|
||||
|
||||
log.Info("开始检测Agent的网络连通情况!")
|
||||
|
||||
outsideTestUrl := "www.google.com"
|
||||
innerTestUrl := "www.baidu.com"
|
||||
|
||||
@@ -109,4 +110,6 @@ func detectByInternet(os *AgentOsOperator) {
|
||||
os.IsAgentInnerWall = true
|
||||
}
|
||||
|
||||
log.InfoF("[Agent Network Status] - Can Access Internet => %s Inner CN => %s", strconv.FormatBool(os.CanAccessInternet), strconv.FormatBool(os.IsAgentInnerWall))
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user