mirror of
https://github.com/yunionio/cloudpods.git
synced 2026-09-24 16:03:43 +08:00
fix(region): sync vm hostname with ascii (#15562)
This commit is contained in:
@@ -2849,7 +2849,7 @@ func (self *SGuest) syncWithCloudVM(ctx context.Context, userCred mcclient.Token
|
||||
}
|
||||
}
|
||||
if extVM.GetName() != extVM.GetHostname() {
|
||||
self.Hostname = extVM.GetHostname()
|
||||
self.Hostname = pinyinutils.Text2Pinyin(extVM.GetHostname())
|
||||
}
|
||||
if !self.IsFailureStatus() && syncStatus {
|
||||
self.Status = extVM.GetStatus()
|
||||
@@ -2965,7 +2965,7 @@ func (manager *SGuestManager) newCloudVM(ctx context.Context, userCred mcclient.
|
||||
guest.Bios = string(extVM.GetBios())
|
||||
guest.Machine = extVM.GetMachine()
|
||||
guest.Hypervisor = extVM.GetHypervisor()
|
||||
guest.Hostname = extVM.GetHostname()
|
||||
guest.Hostname = pinyinutils.Text2Pinyin(extVM.GetHostname())
|
||||
guest.InternetMaxBandwidthOut = extVM.GetInternetMaxBandwidthOut()
|
||||
guest.Throughput = extVM.GetThroughput()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user