Merge pull request #1011 from losipiuk/lo/gce-supported-gpus
Add gpus to supportedResources map in GCE cloud provider
This commit is contained in:
commit
bbe99a27d8
|
|
@ -96,9 +96,17 @@ var (
|
|||
"https://www.googleapis.com/auth/devstorage.read_only",
|
||||
"https://www.googleapis.com/auth/service.management.readonly",
|
||||
"https://www.googleapis.com/auth/servicecontrol"}
|
||||
supportedResources = map[string]bool{cloudprovider.ResourceNameCores: true, cloudprovider.ResourceNameMemory: true}
|
||||
supportedResources = map[string]bool{}
|
||||
)
|
||||
|
||||
func init() {
|
||||
supportedResources[cloudprovider.ResourceNameCores] = true
|
||||
supportedResources[cloudprovider.ResourceNameMemory] = true
|
||||
for _, gpuType := range supportedGpuTypes {
|
||||
supportedResources[gpuType] = true
|
||||
}
|
||||
}
|
||||
|
||||
type migInformation struct {
|
||||
config *Mig
|
||||
basename string
|
||||
|
|
|
|||
|
|
@ -83,6 +83,12 @@ var (
|
|||
8: 96,
|
||||
},
|
||||
}
|
||||
|
||||
supportedGpuTypes = []string{
|
||||
"nvidia-tesla-k80",
|
||||
"nvidia-tesla-p100",
|
||||
"nvidia-tesla-v100",
|
||||
}
|
||||
)
|
||||
|
||||
func validateGpuConfig(gpuType string, gpuCount int64, zone, machineType string) error {
|
||||
|
|
|
|||
Loading…
Reference in New Issue