diff --git a/server/ansible-script/ansible-adhoc.cfg b/server/ansible-script/ansible-adhoc.cfg index 61f39efd..4be0ba85 100644 --- a/server/ansible-script/ansible-adhoc.cfg +++ b/server/ansible-script/ansible-adhoc.cfg @@ -15,6 +15,7 @@ roles_path = ./roles:$VIRTUAL_ENV/usr/local/share/kubespray/roles:$VIRTUAL_ENV/u deprecation_warnings=False inventory_ignore_extensions = ~, .orig, .bak, .ini, .cfg, .retry, .pyc, .pyo, .creds, .gpg +forks=100 force_color=False interpreter_python=auto diff --git a/server/api/cluster/state/ping_pong.go b/server/api/cluster/state/ping_pong.go index f7bff467..6e84dbe0 100644 --- a/server/api/cluster/state/ping_pong.go +++ b/server/api/cluster/state/ping_pong.go @@ -59,8 +59,8 @@ func PingPong(clusterName string, nodes string) (*PingPongResult, error) { // "--timeout", "20", "-e", "kuboardspray_cluster_dir=" + constants.GET_DATA_DIR() + "/cluster/" + clusterName, }, - Env: []string{"ANSIBLE_CONFIG=" + constants.GET_ADHOC_CFG_PATH()}, - Timeout: 20, + Env: []string{"ANSIBLE_CONFIG=" + constants.GET_ADHOC_CFG_PATH()}, + // Timeout: 20, // Dir: resourcePackageDir, } stdout, stderr, err := cmd.Run() diff --git a/server/api/fact/facts.go b/server/api/fact/facts.go index d2553609..4dcd194f 100644 --- a/server/api/fact/facts.go +++ b/server/api/fact/facts.go @@ -102,10 +102,10 @@ func nodefacts(req GetNodeFactRequest) (*gin.H, error) { defer os.Remove(inventoryPath) run := command.Run{ - Cmd: "ansible", - Args: []string{req.Node, "-m", "setup", "-i", inventoryPath}, - Env: []string{"ANSIBLE_CONFIG=" + constants.GET_ADHOC_CFG_PATH()}, - Timeout: 5, + Cmd: "ansible", + Args: []string{req.Node, "-m", "setup", "-i", inventoryPath}, + Env: []string{"ANSIBLE_CONFIG=" + constants.GET_ADHOC_CFG_PATH()}, + // Timeout: 5, // Dir: dir + "/ansible-script", }