diff --git a/hack/machine_types/machine_types.go b/hack/machine_types/machine_types.go index 5aa3e48679..7d130169e7 100644 --- a/hack/machine_types/machine_types.go +++ b/hack/machine_types/machine_types.go @@ -153,6 +153,7 @@ func run() error { } } + seen := map[string]bool{} for _, item := range prices { for k, v := range item { if k == "product" { @@ -162,6 +163,11 @@ func run() error { attributes[k] = v.(string) } + if _, ok := seen[attributes["instanceType"]]; ok { + continue + } + seen[attributes["instanceType"]] = true + machine := awsup.AWSMachineTypeInfo{ Name: attributes["instanceType"], Cores: stringToInt(attributes["vcpu"]),