Skip to content

Commit

Permalink
Merge pull request #18865 from wanyaoqi/automated-cherry-pick-of-#188…
Browse files Browse the repository at this point in the history
…64-upstream-master

Automated cherry pick of #18864: Automated cherry pick of #18863: fix(host-deployer,host): mv deploy driver option to common options
  • Loading branch information
zexi authored Dec 4, 2023
2 parents 1105454 + 3553fc9 commit af4f1b3
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
3 changes: 2 additions & 1 deletion pkg/cloudcommon/options/options.go
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,8 @@ type HostCommonOptions struct {

EnableRemoteExecutor bool `help:"Enable remote executor" default:"false"`

ExecutorConnectTimeoutSeconds int `help:"executor client connection timeout in seconds, default is 30" default:"30"`
ExecutorConnectTimeoutSeconds int `help:"executor client connection timeout in seconds, default is 30" default:"30"`
ImageDeployDriver string `help:"Image deploy driver" default:"qemu-kvm" choices:"qemu-kvm|nbd|libguestfs"`
}

type DBOptions struct {
Expand Down
5 changes: 2 additions & 3 deletions pkg/hostman/hostdeployer/deployserver/options.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,8 @@ type SDeployOptions struct {
PrivatePrefixes []string `help:"IPv4 private prefixes"`
ChntpwPath string `help:"path to chntpw tool" default:"/usr/local/bin/chntpw.static"`

CloudrootDir string `help:"User cloudroot home dir" default:"/opt"`
ImageDeployDriver string `help:"Image deploy driver" default:"qemu-kvm" choices:"qemu-kvm|nbd|libguestfs"`
CommonConfigFile string `help:"common config file for container"`
CloudrootDir string `help:"User cloudroot home dir" default:"/opt"`
CommonConfigFile string `help:"common config file for container"`

DeployTempDir string `help:"temp dir for deployer" default:"/opt/cloud/workspace/run/deploy"`

Expand Down
6 changes: 3 additions & 3 deletions pkg/hostman/hostinfo/hostinfo.go
Original file line number Diff line number Diff line change
Expand Up @@ -2355,10 +2355,10 @@ func (h *SHostInfo) getNicsTelegrafConf() []map[string]interface{} {
}

func (h *SHostInfo) getHostname() string {
if len(h.FullName) > 0 {
return h.FullName
if h.FullName == "" {
h.FullName = h.fetchHostname()
}
return h.fetchHostname()
return h.FullName
}

func (h *SHostInfo) GetCpuArchitecture() string {
Expand Down

0 comments on commit af4f1b3

Please sign in to comment.