Merge pull request #801 from AnanyaKumar/cloud-provider-fix
Fix incorrect use of metadata library, correct typo
This commit is contained in:
commit
d93f16c442
@ -125,7 +125,7 @@ type InstanceType string
|
||||
|
||||
const (
|
||||
NoInstance InstanceType = "None"
|
||||
UnknownInstance = "Uknown"
|
||||
UnknownInstance = "Unknown"
|
||||
)
|
||||
|
||||
type MachineInfo struct {
|
||||
|
@ -26,7 +26,7 @@ func onGCE() bool {
|
||||
}
|
||||
|
||||
func getGceInstanceType() info.InstanceType {
|
||||
machineType, err := metadata.Get("machine-type")
|
||||
machineType, err := metadata.Get("instance/machine-type")
|
||||
if err != nil {
|
||||
return info.UnknownInstance
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user