mirror of
https://github.com/yunionio/cloudpods.git
synced 2026-10-28 03:23:25 +08:00
Automatic merge from release/2.1.0 -> release/2.2.0
* commit '62e269b20f3639fd21a9aeb986bbe89959aef60c': webconsole: support baremetal ipmitool sol
This commit is contained in:
@@ -12,12 +12,12 @@ import (
|
||||
)
|
||||
|
||||
func init() {
|
||||
handleResult := func(opt o.WebConsoleFrontendOptions, obj jsonutils.JSONObject) error {
|
||||
if opt.WebUrl == "" {
|
||||
handleResult := func(opt o.WebConsoleOptions, obj jsonutils.JSONObject) error {
|
||||
if opt.WebconsoleUrl == "" {
|
||||
printObject(obj)
|
||||
return nil
|
||||
}
|
||||
u, err := url.Parse(opt.WebUrl)
|
||||
u, err := url.Parse(opt.WebconsoleUrl)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
@@ -40,7 +40,7 @@ func init() {
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
handleResult(args.WebConsoleFrontendOptions, ret)
|
||||
handleResult(args.WebConsoleOptions, ret)
|
||||
return nil
|
||||
})
|
||||
|
||||
@@ -53,7 +53,16 @@ func init() {
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
handleResult(args.WebConsoleFrontendOptions, ret)
|
||||
handleResult(args.WebConsoleOptions, ret)
|
||||
return nil
|
||||
})
|
||||
|
||||
R(&o.WebConsoleBaremetalOptions{}, "webconsole-baremetal", "Connect baremetal host webconsole", func(s *mcclient.ClientSession, args *o.WebConsoleBaremetalOptions) error {
|
||||
ret, err := modules.WebConsole.DoBaremetalConnect(s, args.ID)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
handleResult(args.WebConsoleOptions, ret)
|
||||
return nil
|
||||
})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user