diff --git a/hack/contrib/docker/gateway/nginx/lua/balancer.lua b/hack/contrib/docker/gateway/nginx/lua/balancer.lua index 893b3484e..8ca19cf97 100644 --- a/hack/contrib/docker/gateway/nginx/lua/balancer.lua +++ b/hack/contrib/docker/gateway/nginx/lua/balancer.lua @@ -133,6 +133,7 @@ function _M.balance() if not ok then ngx.log(ngx.ERR, string.format("error while setting current upstream peer %s: %s", peer, err)) end + ngx.log(ngx.INFO, string.format("successfully set current upstream peer %s: %s", peer, err)) end return _M \ No newline at end of file diff --git a/hack/contrib/docker/gateway/nginx/lua/config.lua b/hack/contrib/docker/gateway/nginx/lua/config.lua index d89ced142..a8f0ebd54 100644 --- a/hack/contrib/docker/gateway/nginx/lua/config.lua +++ b/hack/contrib/docker/gateway/nginx/lua/config.lua @@ -48,8 +48,8 @@ end function _M.call() if ngx.var.request_method ~= "POST" and ngx.var.request_method ~= "GET" then + ngx.log(ngx.ERR, "Only POST and GET requests are allowed!") ngx.status = ngx.HTTP_BAD_REQUEST - ngx.print("Only POST and GET requests are allowed!") return end @@ -79,6 +79,7 @@ function _M.call() return end + ngx.log(ngx.INFO, "successfully read or update backend data ") ngx.status = ngx.HTTP_CREATED end diff --git a/hack/contrib/docker/gateway/nginxtmp/tmpl/nginx.tmpl b/hack/contrib/docker/gateway/nginxtmp/tmpl/nginx.tmpl index ccc589205..1258efbc5 100644 --- a/hack/contrib/docker/gateway/nginxtmp/tmpl/nginx.tmpl +++ b/hack/contrib/docker/gateway/nginxtmp/tmpl/nginx.tmpl @@ -101,6 +101,7 @@ http { server 0.0.0.1; # placeholder balancer_by_lua_block { + ngx.log(ngx.INFO, string.format("start balancer")) balancer.balance() } } diff --git a/node/core/service/node_service.go b/node/core/service/node_service.go index 8f2a8f8cb..c1b9d4125 100644 --- a/node/core/service/node_service.go +++ b/node/core/service/node_service.go @@ -131,7 +131,7 @@ func (n *NodeService) AsynchronousInstall(node *client.HostNode) { } // start add node script logrus.Info("Begin add node, please don't exit") - line := fmt.Sprintf("cd /opt/rainbond/install/scripts; ./%s.sh %s %s %s %s %s %s", node.Role[0], node.HostName, + line := fmt.Sprintf("cd /opt/rainbond/rainbond-ansible/scripts; ./%s.sh %s %s %s %s %s %s", node.Role[0], node.HostName, node.InternalIP, linkModel, node.RootPass, node.KeyPath, node.ID) fileName := node.HostName + ".log"