mirror of
https://gitee.com/rainbond/Rainbond.git
synced 2024-11-30 02:38:17 +08:00
[REV] add compute node uid to init script
This commit is contained in:
parent
992dea9342
commit
71dee0d194
@ -203,7 +203,7 @@ func NewCmdNode() cli.Command {
|
||||
Usage: "RootPass",
|
||||
},
|
||||
cli.StringSliceFlag{
|
||||
Name: "Role,r",
|
||||
Name: "Role,ro",
|
||||
Usage: "Role|required",
|
||||
},
|
||||
},
|
||||
|
@ -299,8 +299,9 @@ func (n *NodeCluster) checkNodeInstall(node *model.HostNode) {
|
||||
var stdout bytes.Buffer
|
||||
var stderr bytes.Buffer
|
||||
role:=node.Role[0]
|
||||
|
||||
etcd:=n.currentNode.InternalIP
|
||||
cmd:="bash -c \"set "+etcd+" "+role+";$(curl -s repo.goodrain.com/gaops/jobs/install/prepare/init.sh)\""
|
||||
cmd:="bash -c \"set "+node.ID+" "+etcd+" "+role+";$(curl -s repo.goodrain.com/gaops/jobs/install/prepare/init.sh)\""
|
||||
logrus.Infof("init endpoint node cmd is %s",cmd)
|
||||
client := util.NewSSHClient(node.InternalIP, "root", node.RootPass, cmd, 22, &stdout, &stderr)
|
||||
if err := client.Connection(); err != nil {
|
||||
|
Loading…
Reference in New Issue
Block a user