Merge pull request #12280 from ioito/automated-cherry-pick-of-#12278-upstream-release-3.7

Automated cherry pick of #12278: fix(region): google vm mac addr
This commit is contained in:
Zexi Li
2021-09-24 15:25:35 +08:00
committed by GitHub
2 changed files with 2 additions and 4 deletions
+1 -3
View File
@@ -290,10 +290,8 @@ func (instance *SInstance) GetOsType() cloudprovider.TOsType {
for _, disk := range instance.Disks {
if disk.Index == 0 {
for _, license := range disk.Licenses {
if strings.Index(strings.ToLower(license), "windows") < 0 {
if strings.Contains(strings.ToLower(license), "windows") {
return cloudprovider.OsTypeWindows
} else {
return cloudprovider.OsTypeLinux
}
}
}
+1 -1
View File
@@ -45,7 +45,7 @@ func (nic *SNetworkInterface) GetIP() string {
func (nic *SNetworkInterface) GetMAC() string {
ip, _ := netutils.NewIPV4Addr(nic.NetworkIP)
return ip.ToMac("00:16:")
return ip.ToMac("42:01:")
}
func (nic *SNetworkInterface) GetDriver() string {