mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-06 02:34:03 +00:00
Merge pull request #119603 from borg-land/machine-type-fix
Calculate the correct machine-type
This commit is contained in:
commit
97c7dbcd22
@ -768,12 +768,15 @@ func (g *GCERunner) updateKernelArguments(instance *compute.Instance, image stri
|
||||
}
|
||||
|
||||
func (g *GCERunner) machineType(machine string) string {
|
||||
var ret string
|
||||
if machine == "" && *instanceType != "" {
|
||||
machine = *instanceType
|
||||
ret = *instanceType
|
||||
} else if machine != "" {
|
||||
ret = machine
|
||||
} else {
|
||||
machine = defaultGCEMachine
|
||||
ret = defaultGCEMachine
|
||||
}
|
||||
return fmt.Sprintf("zones/%s/machineTypes/%s", *zone, machine)
|
||||
return fmt.Sprintf("zones/%s/machineTypes/%s", *zone, ret)
|
||||
}
|
||||
func (g *GCERunner) rebootInstance(instance *compute.Instance) error {
|
||||
// wait until the instance will not response to SSH
|
||||
|
Loading…
Reference in New Issue
Block a user