From ace0fc6166ace9e36ea446872620e5e8a84c8b5a Mon Sep 17 00:00:00 2001 From: Alex Leites <18728999+tallaxes@users.noreply.github.com> Date: Mon, 16 Dec 2024 17:06:30 -0800 Subject: [PATCH] fix: temp exclude SKUs without compatible VM image (#617) * fix: temp exclude SKUs without compatible CIG image * test: temp exclude SKUs without compatible CIG image (using Standard_D2as_v6) --- hack/codegen.sh | 2 +- pkg/fake/zz_generated.sku.eastus.go | 150 +++++++++++++++----- pkg/fake/zz_generated.sku.westcentralus.go | 134 ++++++++++++++--- pkg/providers/instancetype/instancetypes.go | 21 ++- pkg/providers/instancetype/suite_test.go | 3 + 5 files changed, 250 insertions(+), 60 deletions(-) diff --git a/hack/codegen.sh b/hack/codegen.sh index 581be327d..2fb645c30 100755 --- a/hack/codegen.sh +++ b/hack/codegen.sh @@ -32,7 +32,7 @@ skugen() { NO_UPDATE=" pkg/fake/zz_generated.sku.$location.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)" SUBJECT="SKUGEN" - go run hack/code/instancetype_testdata_gen/main.go -- "${GENERATED_FILE}" "$location" "Standard_B1s,Standard_A0,Standard_D2_v2,Standard_D2_v3,Standard_DS2_v2,Standard_D2s_v3,Standard_D2_v5,Standard_D16plds_v5,Standard_F16s_v2,Standard_NC6s,Standard_NC6s_v3,Standard_NC16as_T4_v3,Standard_NC24ads_A100_v4,Standard_M8-2ms,Standard_D4s_v3,Standard_D64s_v3,Standard_DC8s_v3" + go run hack/code/instancetype_testdata_gen/main.go -- "${GENERATED_FILE}" "$location" "Standard_B1s,Standard_A0,Standard_D2_v2,Standard_D2_v3,Standard_DS2_v2,Standard_D2s_v3,Standard_D2_v5,Standard_D16plds_v5,Standard_F16s_v2,Standard_NC6s,Standard_NC6s_v3,Standard_NC16as_T4_v3,Standard_NC24ads_A100_v4,Standard_M8-2ms,Standard_D4s_v3,Standard_D64s_v3,Standard_DC8s_v3,Standard_D2as_v6" go fmt "${GENERATED_FILE}" GIT_DIFF=$(git diff --stat "${GENERATED_FILE}") diff --git a/pkg/fake/zz_generated.sku.eastus.go b/pkg/fake/zz_generated.sku.eastus.go index a36d2186a..0cc25d4ef 100644 --- a/pkg/fake/zz_generated.sku.eastus.go +++ b/pkg/fake/zz_generated.sku.eastus.go @@ -24,7 +24,7 @@ import ( "github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2022-08-01/compute" ) -// generated at 2024-01-12T06:16:27Z +// generated at 2024-12-13T00:09:51Z func init() { // ResourceSkus is a list of selected VM SKUs for a given region @@ -70,6 +70,11 @@ func init() { {Name: lo.ToPtr("vCPUsAvailable"), Value: lo.ToPtr("1")}, {Name: lo.ToPtr("ACUs"), Value: lo.ToPtr("50")}, {Name: lo.ToPtr("vCPUsPerCore"), Value: lo.ToPtr("1")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedIOPS"), Value: lo.ToPtr("1000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("20971520")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("10485760")}, + {Name: lo.ToPtr("UncachedDiskIOPS"), Value: lo.ToPtr("1600")}, + {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("24000000")}, {Name: lo.ToPtr("EphemeralOSDiskSupported"), Value: lo.ToPtr("False")}, {Name: lo.ToPtr("EncryptionAtHostSupported"), Value: lo.ToPtr("False")}, {Name: lo.ToPtr("CapacityReservationSupported"), Value: lo.ToPtr("False")}, @@ -96,6 +101,7 @@ func init() { {Name: lo.ToPtr("vCPUs"), Value: lo.ToPtr("1")}, {Name: lo.ToPtr("MemoryPreservingMaintenanceSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("HyperVGenerations"), Value: lo.ToPtr("V1,V2")}, + {Name: lo.ToPtr("SupportedEphemeralOSDiskPlacements"), Value: lo.ToPtr("ResourceDisk,CacheDisk")}, {Name: lo.ToPtr("MemoryGB"), Value: lo.ToPtr("1")}, {Name: lo.ToPtr("MaxDataDiskCount"), Value: lo.ToPtr("2")}, {Name: lo.ToPtr("CpuArchitectureType"), Value: lo.ToPtr("x64")}, @@ -142,6 +148,7 @@ func init() { {Name: lo.ToPtr("vCPUs"), Value: lo.ToPtr("16")}, {Name: lo.ToPtr("MemoryPreservingMaintenanceSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("HyperVGenerations"), Value: lo.ToPtr("V2")}, + {Name: lo.ToPtr("SupportedEphemeralOSDiskPlacements"), Value: lo.ToPtr("ResourceDisk,CacheDisk")}, {Name: lo.ToPtr("MemoryGB"), Value: lo.ToPtr("32")}, {Name: lo.ToPtr("MaxDataDiskCount"), Value: lo.ToPtr("32")}, {Name: lo.ToPtr("CpuArchitectureType"), Value: lo.ToPtr("Arm64")}, @@ -173,6 +180,53 @@ func init() { }, }, }, + { + Name: lo.ToPtr("Standard_D2as_v6"), + Tier: lo.ToPtr("Standard"), + Kind: lo.ToPtr(""), + Size: lo.ToPtr("D2as_v6"), + Family: lo.ToPtr("standardDav6Family"), + ResourceType: lo.ToPtr("virtualMachines"), + APIVersions: &[]string{}, + Costs: &[]compute.ResourceSkuCosts{}, + Restrictions: &[]compute.ResourceSkuRestrictions{}, + Capabilities: &[]compute.ResourceSkuCapabilities{ + {Name: lo.ToPtr("MaxResourceVolumeMB"), Value: lo.ToPtr("0")}, + {Name: lo.ToPtr("OSVhdSizeMB"), Value: lo.ToPtr("1047552")}, + {Name: lo.ToPtr("vCPUs"), Value: lo.ToPtr("2")}, + {Name: lo.ToPtr("MemoryPreservingMaintenanceSupported"), Value: lo.ToPtr("True")}, + {Name: lo.ToPtr("HyperVGenerations"), Value: lo.ToPtr("V2")}, + {Name: lo.ToPtr("DiskControllerTypes"), Value: lo.ToPtr("NVMe")}, + {Name: lo.ToPtr("MemoryGB"), Value: lo.ToPtr("8")}, + {Name: lo.ToPtr("MaxDataDiskCount"), Value: lo.ToPtr("4")}, + {Name: lo.ToPtr("CpuArchitectureType"), Value: lo.ToPtr("x64")}, + {Name: lo.ToPtr("LowPriorityCapable"), Value: lo.ToPtr("True")}, + {Name: lo.ToPtr("PremiumIO"), Value: lo.ToPtr("True")}, + {Name: lo.ToPtr("VMDeploymentTypes"), Value: lo.ToPtr("IaaS")}, + {Name: lo.ToPtr("vCPUsAvailable"), Value: lo.ToPtr("2")}, + {Name: lo.ToPtr("ACUs"), Value: lo.ToPtr("230")}, + {Name: lo.ToPtr("vCPUsPerCore"), Value: lo.ToPtr("2")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedIOPS"), Value: lo.ToPtr("9000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("125000000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("125000000")}, + {Name: lo.ToPtr("UncachedDiskIOPS"), Value: lo.ToPtr("4000")}, + {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("90000000")}, + {Name: lo.ToPtr("EphemeralOSDiskSupported"), Value: lo.ToPtr("False")}, + {Name: lo.ToPtr("EncryptionAtHostSupported"), Value: lo.ToPtr("True")}, + {Name: lo.ToPtr("CapacityReservationSupported"), Value: lo.ToPtr("False")}, + {Name: lo.ToPtr("AcceleratedNetworkingEnabled"), Value: lo.ToPtr("True")}, + {Name: lo.ToPtr("RdmaEnabled"), Value: lo.ToPtr("False")}, + {Name: lo.ToPtr("MaxNetworkInterfaces"), Value: lo.ToPtr("2")}, + }, + Locations: &[]string{"eastus"}, + LocationInfo: &[]compute.ResourceSkuLocationInfo{{Location: lo.ToPtr("eastus"), Zones: &[]string{ + "1", + "2", + "3", + }, + }, + }, + }, { Name: lo.ToPtr("Standard_D2s_v3"), Tier: lo.ToPtr("Standard"), @@ -189,6 +243,7 @@ func init() { {Name: lo.ToPtr("vCPUs"), Value: lo.ToPtr("2")}, {Name: lo.ToPtr("MemoryPreservingMaintenanceSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("HyperVGenerations"), Value: lo.ToPtr("V1,V2")}, + {Name: lo.ToPtr("SupportedEphemeralOSDiskPlacements"), Value: lo.ToPtr("ResourceDisk,CacheDisk")}, {Name: lo.ToPtr("MemoryGB"), Value: lo.ToPtr("8")}, {Name: lo.ToPtr("MaxDataDiskCount"), Value: lo.ToPtr("4")}, {Name: lo.ToPtr("CpuArchitectureType"), Value: lo.ToPtr("x64")}, @@ -199,11 +254,11 @@ func init() { {Name: lo.ToPtr("ACUs"), Value: lo.ToPtr("160")}, {Name: lo.ToPtr("vCPUsPerCore"), Value: lo.ToPtr("2")}, {Name: lo.ToPtr("CombinedTempDiskAndCachedIOPS"), Value: lo.ToPtr("4000")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("33554432")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("33554432")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("32768000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("32768000")}, {Name: lo.ToPtr("CachedDiskBytes"), Value: lo.ToPtr("53687091200")}, {Name: lo.ToPtr("UncachedDiskIOPS"), Value: lo.ToPtr("3200")}, - {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("50331648")}, + {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("48000000")}, {Name: lo.ToPtr("EphemeralOSDiskSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("EncryptionAtHostSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("CapacityReservationSupported"), Value: lo.ToPtr("False")}, @@ -246,8 +301,10 @@ func init() { {Name: lo.ToPtr("ACUs"), Value: lo.ToPtr("210")}, {Name: lo.ToPtr("vCPUsPerCore"), Value: lo.ToPtr("1")}, {Name: lo.ToPtr("CombinedTempDiskAndCachedIOPS"), Value: lo.ToPtr("6000")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("97517568")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("48234496")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("98304000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("49152000")}, + {Name: lo.ToPtr("UncachedDiskIOPS"), Value: lo.ToPtr("6400")}, + {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("96000000")}, {Name: lo.ToPtr("EphemeralOSDiskSupported"), Value: lo.ToPtr("False")}, {Name: lo.ToPtr("EncryptionAtHostSupported"), Value: lo.ToPtr("False")}, {Name: lo.ToPtr("CapacityReservationSupported"), Value: lo.ToPtr("False")}, @@ -290,8 +347,10 @@ func init() { {Name: lo.ToPtr("ACUs"), Value: lo.ToPtr("160")}, {Name: lo.ToPtr("vCPUsPerCore"), Value: lo.ToPtr("2")}, {Name: lo.ToPtr("CombinedTempDiskAndCachedIOPS"), Value: lo.ToPtr("3000")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("48234496")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("24117248")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("49152000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("24576000")}, + {Name: lo.ToPtr("UncachedDiskIOPS"), Value: lo.ToPtr("3200")}, + {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("48000000")}, {Name: lo.ToPtr("EphemeralOSDiskSupported"), Value: lo.ToPtr("False")}, {Name: lo.ToPtr("EncryptionAtHostSupported"), Value: lo.ToPtr("False")}, {Name: lo.ToPtr("CapacityReservationSupported"), Value: lo.ToPtr("False")}, @@ -332,11 +391,11 @@ func init() { {Name: lo.ToPtr("VMDeploymentTypes"), Value: lo.ToPtr("IaaS")}, {Name: lo.ToPtr("vCPUsAvailable"), Value: lo.ToPtr("2")}, {Name: lo.ToPtr("vCPUsPerCore"), Value: lo.ToPtr("2")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedIOPS"), Value: lo.ToPtr("19000")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("131072000")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("131072000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedIOPS"), Value: lo.ToPtr("9000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("125000000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("125000000")}, {Name: lo.ToPtr("UncachedDiskIOPS"), Value: lo.ToPtr("3750")}, - {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("89128960")}, + {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("85000000")}, {Name: lo.ToPtr("EphemeralOSDiskSupported"), Value: lo.ToPtr("False")}, {Name: lo.ToPtr("EncryptionAtHostSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("CapacityReservationSupported"), Value: lo.ToPtr("False")}, @@ -369,6 +428,7 @@ func init() { {Name: lo.ToPtr("vCPUs"), Value: lo.ToPtr("4")}, {Name: lo.ToPtr("MemoryPreservingMaintenanceSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("HyperVGenerations"), Value: lo.ToPtr("V1,V2")}, + {Name: lo.ToPtr("SupportedEphemeralOSDiskPlacements"), Value: lo.ToPtr("ResourceDisk,CacheDisk")}, {Name: lo.ToPtr("MemoryGB"), Value: lo.ToPtr("16")}, {Name: lo.ToPtr("MaxDataDiskCount"), Value: lo.ToPtr("8")}, {Name: lo.ToPtr("CpuArchitectureType"), Value: lo.ToPtr("x64")}, @@ -379,11 +439,11 @@ func init() { {Name: lo.ToPtr("ACUs"), Value: lo.ToPtr("160")}, {Name: lo.ToPtr("vCPUsPerCore"), Value: lo.ToPtr("2")}, {Name: lo.ToPtr("CombinedTempDiskAndCachedIOPS"), Value: lo.ToPtr("8000")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("67108864")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("67108864")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("65536000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("65536000")}, {Name: lo.ToPtr("CachedDiskBytes"), Value: lo.ToPtr("107374182400")}, {Name: lo.ToPtr("UncachedDiskIOPS"), Value: lo.ToPtr("6400")}, - {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("100663296")}, + {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("96000000")}, {Name: lo.ToPtr("EphemeralOSDiskSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("EncryptionAtHostSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("CapacityReservationSupported"), Value: lo.ToPtr("False")}, @@ -416,6 +476,7 @@ func init() { {Name: lo.ToPtr("vCPUs"), Value: lo.ToPtr("64")}, {Name: lo.ToPtr("MemoryPreservingMaintenanceSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("HyperVGenerations"), Value: lo.ToPtr("V1,V2")}, + {Name: lo.ToPtr("SupportedEphemeralOSDiskPlacements"), Value: lo.ToPtr("ResourceDisk,CacheDisk")}, {Name: lo.ToPtr("MemoryGB"), Value: lo.ToPtr("256")}, {Name: lo.ToPtr("MaxDataDiskCount"), Value: lo.ToPtr("32")}, {Name: lo.ToPtr("CpuArchitectureType"), Value: lo.ToPtr("x64")}, @@ -426,11 +487,11 @@ func init() { {Name: lo.ToPtr("ACUs"), Value: lo.ToPtr("160")}, {Name: lo.ToPtr("vCPUsPerCore"), Value: lo.ToPtr("2")}, {Name: lo.ToPtr("CombinedTempDiskAndCachedIOPS"), Value: lo.ToPtr("128000")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("1073741824")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("1073741824")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("1048576000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("1048576000")}, {Name: lo.ToPtr("CachedDiskBytes"), Value: lo.ToPtr("1717986918400")}, {Name: lo.ToPtr("UncachedDiskIOPS"), Value: lo.ToPtr("80000")}, - {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("1258291200")}, + {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("1200000000")}, {Name: lo.ToPtr("EphemeralOSDiskSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("EncryptionAtHostSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("CapacityReservationSupported"), Value: lo.ToPtr("False")}, @@ -474,8 +535,8 @@ func init() { {Name: lo.ToPtr("CombinedTempDiskAndCachedIOPS"), Value: lo.ToPtr("77000")}, {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("77000000000")}, {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("77000000000")}, - {Name: lo.ToPtr("UncachedDiskIOPS"), Value: lo.ToPtr("25600")}, - {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("384000000")}, + {Name: lo.ToPtr("UncachedDiskIOPS"), Value: lo.ToPtr("12800")}, + {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("201326592")}, {Name: lo.ToPtr("EphemeralOSDiskSupported"), Value: lo.ToPtr("False")}, {Name: lo.ToPtr("EncryptionAtHostSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("CapacityReservationSupported"), Value: lo.ToPtr("False")}, @@ -506,6 +567,7 @@ func init() { {Name: lo.ToPtr("vCPUs"), Value: lo.ToPtr("2")}, {Name: lo.ToPtr("MemoryPreservingMaintenanceSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("HyperVGenerations"), Value: lo.ToPtr("V1,V2")}, + {Name: lo.ToPtr("SupportedEphemeralOSDiskPlacements"), Value: lo.ToPtr("ResourceDisk,CacheDisk")}, {Name: lo.ToPtr("MemoryGB"), Value: lo.ToPtr("7")}, {Name: lo.ToPtr("MaxDataDiskCount"), Value: lo.ToPtr("8")}, {Name: lo.ToPtr("CpuArchitectureType"), Value: lo.ToPtr("x64")}, @@ -553,6 +615,7 @@ func init() { {Name: lo.ToPtr("vCPUs"), Value: lo.ToPtr("16")}, {Name: lo.ToPtr("MemoryPreservingMaintenanceSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("HyperVGenerations"), Value: lo.ToPtr("V1,V2")}, + {Name: lo.ToPtr("SupportedEphemeralOSDiskPlacements"), Value: lo.ToPtr("ResourceDisk,CacheDisk")}, {Name: lo.ToPtr("MemoryGB"), Value: lo.ToPtr("32")}, {Name: lo.ToPtr("MaxDataDiskCount"), Value: lo.ToPtr("32")}, {Name: lo.ToPtr("CpuArchitectureType"), Value: lo.ToPtr("x64")}, @@ -609,11 +672,12 @@ func init() { }, }, Capabilities: &[]compute.ResourceSkuCapabilities{ - {Name: lo.ToPtr("MaxResourceVolumeMB"), Value: lo.ToPtr("256000")}, + {Name: lo.ToPtr("MaxResourceVolumeMB"), Value: lo.ToPtr("262144")}, {Name: lo.ToPtr("OSVhdSizeMB"), Value: lo.ToPtr("1047552")}, {Name: lo.ToPtr("vCPUs"), Value: lo.ToPtr("8")}, {Name: lo.ToPtr("MemoryPreservingMaintenanceSupported"), Value: lo.ToPtr("False")}, {Name: lo.ToPtr("HyperVGenerations"), Value: lo.ToPtr("V1,V2")}, + {Name: lo.ToPtr("SupportedEphemeralOSDiskPlacements"), Value: lo.ToPtr("ResourceDisk,CacheDisk")}, {Name: lo.ToPtr("MemoryGB"), Value: lo.ToPtr("218.75")}, {Name: lo.ToPtr("MaxDataDiskCount"), Value: lo.ToPtr("8")}, {Name: lo.ToPtr("CpuArchitectureType"), Value: lo.ToPtr("x64")}, @@ -626,11 +690,11 @@ func init() { {Name: lo.ToPtr("ParentSize"), Value: lo.ToPtr("Standard_M8ms")}, {Name: lo.ToPtr("vCPUsPerCore"), Value: lo.ToPtr("2")}, {Name: lo.ToPtr("CombinedTempDiskAndCachedIOPS"), Value: lo.ToPtr("10000")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("104857600")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("104857600")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("100000000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("100000000")}, {Name: lo.ToPtr("CachedDiskBytes"), Value: lo.ToPtr("851477266432")}, {Name: lo.ToPtr("UncachedDiskIOPS"), Value: lo.ToPtr("5000")}, - {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("131072000")}, + {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("125000000")}, {Name: lo.ToPtr("EphemeralOSDiskSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("EncryptionAtHostSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("CapacityReservationSupported"), Value: lo.ToPtr("False")}, @@ -664,6 +728,7 @@ func init() { {Name: lo.ToPtr("vCPUs"), Value: lo.ToPtr("16")}, {Name: lo.ToPtr("MemoryPreservingMaintenanceSupported"), Value: lo.ToPtr("False")}, {Name: lo.ToPtr("HyperVGenerations"), Value: lo.ToPtr("V1,V2")}, + {Name: lo.ToPtr("SupportedEphemeralOSDiskPlacements"), Value: lo.ToPtr("ResourceDisk,CacheDisk")}, {Name: lo.ToPtr("MemoryGB"), Value: lo.ToPtr("110")}, {Name: lo.ToPtr("MaxDataDiskCount"), Value: lo.ToPtr("32")}, {Name: lo.ToPtr("CpuArchitectureType"), Value: lo.ToPtr("x64")}, @@ -673,12 +738,12 @@ func init() { {Name: lo.ToPtr("vCPUsAvailable"), Value: lo.ToPtr("16")}, {Name: lo.ToPtr("GPUs"), Value: lo.ToPtr("1")}, {Name: lo.ToPtr("vCPUsPerCore"), Value: lo.ToPtr("1")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedIOPS"), Value: lo.ToPtr("16320")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("251658240")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("251658240")}, - {Name: lo.ToPtr("CachedDiskBytes"), Value: lo.ToPtr("154619000000")}, - {Name: lo.ToPtr("UncachedDiskIOPS"), Value: lo.ToPtr("24480")}, - {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("368640000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedIOPS"), Value: lo.ToPtr("32000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("503316480")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("503316480")}, + {Name: lo.ToPtr("CachedDiskBytes"), Value: lo.ToPtr("154618822656")}, + {Name: lo.ToPtr("UncachedDiskIOPS"), Value: lo.ToPtr("48000")}, + {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("737280000")}, {Name: lo.ToPtr("EphemeralOSDiskSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("EncryptionAtHostSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("CapacityReservationSupported"), Value: lo.ToPtr("False")}, @@ -711,6 +776,7 @@ func init() { {Name: lo.ToPtr("vCPUs"), Value: lo.ToPtr("24")}, {Name: lo.ToPtr("MemoryPreservingMaintenanceSupported"), Value: lo.ToPtr("False")}, {Name: lo.ToPtr("HyperVGenerations"), Value: lo.ToPtr("V2")}, + {Name: lo.ToPtr("SupportedEphemeralOSDiskPlacements"), Value: lo.ToPtr("ResourceDisk,CacheDisk")}, {Name: lo.ToPtr("MemoryGB"), Value: lo.ToPtr("220")}, {Name: lo.ToPtr("MaxDataDiskCount"), Value: lo.ToPtr("8")}, {Name: lo.ToPtr("CpuArchitectureType"), Value: lo.ToPtr("x64")}, @@ -720,13 +786,14 @@ func init() { {Name: lo.ToPtr("vCPUsAvailable"), Value: lo.ToPtr("24")}, {Name: lo.ToPtr("GPUs"), Value: lo.ToPtr("1")}, {Name: lo.ToPtr("vCPUsPerCore"), Value: lo.ToPtr("1")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedIOPS"), Value: lo.ToPtr("75000")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("1000000000")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("1000000000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedIOPS"), Value: lo.ToPtr("32000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("256000000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("256000000")}, {Name: lo.ToPtr("CachedDiskBytes"), Value: lo.ToPtr("274877906944")}, - {Name: lo.ToPtr("UncachedDiskIOPS"), Value: lo.ToPtr("25600")}, - {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("384000000")}, - {Name: lo.ToPtr("NvmeDiskSizeInMiB"), Value: lo.ToPtr("915456")}, + {Name: lo.ToPtr("UncachedDiskIOPS"), Value: lo.ToPtr("30000")}, + {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("1024000000")}, + {Name: lo.ToPtr("NvmeDiskSizeInMiB"), Value: lo.ToPtr("915527")}, + {Name: lo.ToPtr("NvmeSizePerDiskInMiB"), Value: lo.ToPtr("915527")}, {Name: lo.ToPtr("EphemeralOSDiskSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("EncryptionAtHostSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("CapacityReservationSupported"), Value: lo.ToPtr("False")}, @@ -736,7 +803,7 @@ func init() { }, Locations: &[]string{"eastus"}, LocationInfo: &[]compute.ResourceSkuLocationInfo{{Location: lo.ToPtr("eastus"), Zones: &[]string{ - "1", + "3", }, }, }, @@ -768,11 +835,12 @@ func init() { }, }, Capabilities: &[]compute.ResourceSkuCapabilities{ - {Name: lo.ToPtr("MaxResourceVolumeMB"), Value: lo.ToPtr("344064")}, + {Name: lo.ToPtr("MaxResourceVolumeMB"), Value: lo.ToPtr("753664")}, {Name: lo.ToPtr("OSVhdSizeMB"), Value: lo.ToPtr("1047552")}, {Name: lo.ToPtr("vCPUs"), Value: lo.ToPtr("6")}, {Name: lo.ToPtr("MemoryPreservingMaintenanceSupported"), Value: lo.ToPtr("False")}, {Name: lo.ToPtr("HyperVGenerations"), Value: lo.ToPtr("V1,V2")}, + {Name: lo.ToPtr("SupportedEphemeralOSDiskPlacements"), Value: lo.ToPtr("ResourceDisk,CacheDisk")}, {Name: lo.ToPtr("MemoryGB"), Value: lo.ToPtr("112")}, {Name: lo.ToPtr("MaxDataDiskCount"), Value: lo.ToPtr("12")}, {Name: lo.ToPtr("CpuArchitectureType"), Value: lo.ToPtr("x64")}, @@ -782,6 +850,12 @@ func init() { {Name: lo.ToPtr("vCPUsAvailable"), Value: lo.ToPtr("6")}, {Name: lo.ToPtr("GPUs"), Value: lo.ToPtr("1")}, {Name: lo.ToPtr("vCPUsPerCore"), Value: lo.ToPtr("1")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedIOPS"), Value: lo.ToPtr("24000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("210763776")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("210763776")}, + {Name: lo.ToPtr("CachedDiskBytes"), Value: lo.ToPtr("343597383680")}, + {Name: lo.ToPtr("UncachedDiskIOPS"), Value: lo.ToPtr("20000")}, + {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("300000000")}, {Name: lo.ToPtr("EphemeralOSDiskSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("EncryptionAtHostSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("CapacityReservationSupported"), Value: lo.ToPtr("False")}, diff --git a/pkg/fake/zz_generated.sku.westcentralus.go b/pkg/fake/zz_generated.sku.westcentralus.go index a37c219d5..dea4c94f4 100644 --- a/pkg/fake/zz_generated.sku.westcentralus.go +++ b/pkg/fake/zz_generated.sku.westcentralus.go @@ -24,7 +24,7 @@ import ( "github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2022-08-01/compute" ) -// generated at 2023-12-18T15:29:11Z +// generated at 2024-12-13T00:09:53Z func init() { // ResourceSkus is a list of selected VM SKUs for a given region @@ -66,6 +66,11 @@ func init() { {Name: lo.ToPtr("vCPUsAvailable"), Value: lo.ToPtr("1")}, {Name: lo.ToPtr("ACUs"), Value: lo.ToPtr("50")}, {Name: lo.ToPtr("vCPUsPerCore"), Value: lo.ToPtr("1")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedIOPS"), Value: lo.ToPtr("1000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("20971520")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("10485760")}, + {Name: lo.ToPtr("UncachedDiskIOPS"), Value: lo.ToPtr("1600")}, + {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("24000000")}, {Name: lo.ToPtr("EphemeralOSDiskSupported"), Value: lo.ToPtr("False")}, {Name: lo.ToPtr("EncryptionAtHostSupported"), Value: lo.ToPtr("False")}, {Name: lo.ToPtr("CapacityReservationSupported"), Value: lo.ToPtr("False")}, @@ -92,6 +97,7 @@ func init() { {Name: lo.ToPtr("vCPUs"), Value: lo.ToPtr("1")}, {Name: lo.ToPtr("MemoryPreservingMaintenanceSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("HyperVGenerations"), Value: lo.ToPtr("V1,V2")}, + {Name: lo.ToPtr("SupportedEphemeralOSDiskPlacements"), Value: lo.ToPtr("ResourceDisk,CacheDisk")}, {Name: lo.ToPtr("MemoryGB"), Value: lo.ToPtr("1")}, {Name: lo.ToPtr("MaxDataDiskCount"), Value: lo.ToPtr("2")}, {Name: lo.ToPtr("CpuArchitectureType"), Value: lo.ToPtr("x64")}, @@ -116,6 +122,89 @@ func init() { Locations: &[]string{"westcentralus"}, LocationInfo: &[]compute.ResourceSkuLocationInfo{{Location: lo.ToPtr("westcentralus"), Zones: &[]string{}}}, }, + { + Name: lo.ToPtr("Standard_D16plds_v5"), + Tier: lo.ToPtr("Standard"), + Kind: lo.ToPtr(""), + Size: lo.ToPtr("D16plds_v5"), + Family: lo.ToPtr("standardDPLDSv5Family"), + ResourceType: lo.ToPtr("virtualMachines"), + APIVersions: &[]string{}, + Costs: &[]compute.ResourceSkuCosts{}, + Restrictions: &[]compute.ResourceSkuRestrictions{}, + Capabilities: &[]compute.ResourceSkuCapabilities{ + {Name: lo.ToPtr("MaxResourceVolumeMB"), Value: lo.ToPtr("614400")}, + {Name: lo.ToPtr("OSVhdSizeMB"), Value: lo.ToPtr("1047552")}, + {Name: lo.ToPtr("vCPUs"), Value: lo.ToPtr("16")}, + {Name: lo.ToPtr("MemoryPreservingMaintenanceSupported"), Value: lo.ToPtr("True")}, + {Name: lo.ToPtr("HyperVGenerations"), Value: lo.ToPtr("V2")}, + {Name: lo.ToPtr("SupportedEphemeralOSDiskPlacements"), Value: lo.ToPtr("ResourceDisk,CacheDisk")}, + {Name: lo.ToPtr("MemoryGB"), Value: lo.ToPtr("32")}, + {Name: lo.ToPtr("MaxDataDiskCount"), Value: lo.ToPtr("32")}, + {Name: lo.ToPtr("CpuArchitectureType"), Value: lo.ToPtr("Arm64")}, + {Name: lo.ToPtr("LowPriorityCapable"), Value: lo.ToPtr("True")}, + {Name: lo.ToPtr("PremiumIO"), Value: lo.ToPtr("True")}, + {Name: lo.ToPtr("VMDeploymentTypes"), Value: lo.ToPtr("IaaS")}, + {Name: lo.ToPtr("vCPUsAvailable"), Value: lo.ToPtr("16")}, + {Name: lo.ToPtr("vCPUsPerCore"), Value: lo.ToPtr("1")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedIOPS"), Value: lo.ToPtr("75000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("1000000000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("1000000000")}, + {Name: lo.ToPtr("CachedDiskBytes"), Value: lo.ToPtr("429496729600")}, + {Name: lo.ToPtr("UncachedDiskIOPS"), Value: lo.ToPtr("25600")}, + {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("600000000")}, + {Name: lo.ToPtr("EphemeralOSDiskSupported"), Value: lo.ToPtr("True")}, + {Name: lo.ToPtr("EncryptionAtHostSupported"), Value: lo.ToPtr("True")}, + {Name: lo.ToPtr("CapacityReservationSupported"), Value: lo.ToPtr("False")}, + {Name: lo.ToPtr("TrustedLaunchDisabled"), Value: lo.ToPtr("True")}, + {Name: lo.ToPtr("AcceleratedNetworkingEnabled"), Value: lo.ToPtr("True")}, + {Name: lo.ToPtr("RdmaEnabled"), Value: lo.ToPtr("False")}, + {Name: lo.ToPtr("MaxNetworkInterfaces"), Value: lo.ToPtr("4")}, + }, + Locations: &[]string{"westcentralus"}, + LocationInfo: &[]compute.ResourceSkuLocationInfo{{Location: lo.ToPtr("westcentralus"), Zones: &[]string{}}}, + }, + { + Name: lo.ToPtr("Standard_D2as_v6"), + Tier: lo.ToPtr("Standard"), + Kind: lo.ToPtr(""), + Size: lo.ToPtr("D2as_v6"), + Family: lo.ToPtr("standardDav6Family"), + ResourceType: lo.ToPtr("virtualMachines"), + APIVersions: &[]string{}, + Costs: &[]compute.ResourceSkuCosts{}, + Restrictions: &[]compute.ResourceSkuRestrictions{}, + Capabilities: &[]compute.ResourceSkuCapabilities{ + {Name: lo.ToPtr("MaxResourceVolumeMB"), Value: lo.ToPtr("0")}, + {Name: lo.ToPtr("OSVhdSizeMB"), Value: lo.ToPtr("1047552")}, + {Name: lo.ToPtr("vCPUs"), Value: lo.ToPtr("2")}, + {Name: lo.ToPtr("MemoryPreservingMaintenanceSupported"), Value: lo.ToPtr("True")}, + {Name: lo.ToPtr("HyperVGenerations"), Value: lo.ToPtr("V2")}, + {Name: lo.ToPtr("DiskControllerTypes"), Value: lo.ToPtr("NVMe")}, + {Name: lo.ToPtr("MemoryGB"), Value: lo.ToPtr("8")}, + {Name: lo.ToPtr("MaxDataDiskCount"), Value: lo.ToPtr("4")}, + {Name: lo.ToPtr("CpuArchitectureType"), Value: lo.ToPtr("x64")}, + {Name: lo.ToPtr("LowPriorityCapable"), Value: lo.ToPtr("True")}, + {Name: lo.ToPtr("PremiumIO"), Value: lo.ToPtr("True")}, + {Name: lo.ToPtr("VMDeploymentTypes"), Value: lo.ToPtr("IaaS")}, + {Name: lo.ToPtr("vCPUsAvailable"), Value: lo.ToPtr("2")}, + {Name: lo.ToPtr("ACUs"), Value: lo.ToPtr("230")}, + {Name: lo.ToPtr("vCPUsPerCore"), Value: lo.ToPtr("2")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedIOPS"), Value: lo.ToPtr("9000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("125000000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("125000000")}, + {Name: lo.ToPtr("UncachedDiskIOPS"), Value: lo.ToPtr("4000")}, + {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("90000000")}, + {Name: lo.ToPtr("EphemeralOSDiskSupported"), Value: lo.ToPtr("False")}, + {Name: lo.ToPtr("EncryptionAtHostSupported"), Value: lo.ToPtr("True")}, + {Name: lo.ToPtr("CapacityReservationSupported"), Value: lo.ToPtr("False")}, + {Name: lo.ToPtr("AcceleratedNetworkingEnabled"), Value: lo.ToPtr("True")}, + {Name: lo.ToPtr("RdmaEnabled"), Value: lo.ToPtr("False")}, + {Name: lo.ToPtr("MaxNetworkInterfaces"), Value: lo.ToPtr("2")}, + }, + Locations: &[]string{"westcentralus"}, + LocationInfo: &[]compute.ResourceSkuLocationInfo{{Location: lo.ToPtr("westcentralus"), Zones: &[]string{}}}, + }, { Name: lo.ToPtr("Standard_D2s_v3"), Tier: lo.ToPtr("Standard"), @@ -132,6 +221,7 @@ func init() { {Name: lo.ToPtr("vCPUs"), Value: lo.ToPtr("2")}, {Name: lo.ToPtr("MemoryPreservingMaintenanceSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("HyperVGenerations"), Value: lo.ToPtr("V1,V2")}, + {Name: lo.ToPtr("SupportedEphemeralOSDiskPlacements"), Value: lo.ToPtr("ResourceDisk,CacheDisk")}, {Name: lo.ToPtr("MemoryGB"), Value: lo.ToPtr("8")}, {Name: lo.ToPtr("MaxDataDiskCount"), Value: lo.ToPtr("4")}, {Name: lo.ToPtr("CpuArchitectureType"), Value: lo.ToPtr("x64")}, @@ -142,11 +232,11 @@ func init() { {Name: lo.ToPtr("ACUs"), Value: lo.ToPtr("160")}, {Name: lo.ToPtr("vCPUsPerCore"), Value: lo.ToPtr("2")}, {Name: lo.ToPtr("CombinedTempDiskAndCachedIOPS"), Value: lo.ToPtr("4000")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("33554432")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("33554432")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("32768000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("32768000")}, {Name: lo.ToPtr("CachedDiskBytes"), Value: lo.ToPtr("53687091200")}, {Name: lo.ToPtr("UncachedDiskIOPS"), Value: lo.ToPtr("3200")}, - {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("50331648")}, + {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("48000000")}, {Name: lo.ToPtr("EphemeralOSDiskSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("EncryptionAtHostSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("CapacityReservationSupported"), Value: lo.ToPtr("False")}, @@ -183,8 +273,10 @@ func init() { {Name: lo.ToPtr("ACUs"), Value: lo.ToPtr("210")}, {Name: lo.ToPtr("vCPUsPerCore"), Value: lo.ToPtr("1")}, {Name: lo.ToPtr("CombinedTempDiskAndCachedIOPS"), Value: lo.ToPtr("6000")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("97517568")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("48234496")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("98304000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("49152000")}, + {Name: lo.ToPtr("UncachedDiskIOPS"), Value: lo.ToPtr("6400")}, + {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("96000000")}, {Name: lo.ToPtr("EphemeralOSDiskSupported"), Value: lo.ToPtr("False")}, {Name: lo.ToPtr("EncryptionAtHostSupported"), Value: lo.ToPtr("False")}, {Name: lo.ToPtr("CapacityReservationSupported"), Value: lo.ToPtr("False")}, @@ -221,8 +313,10 @@ func init() { {Name: lo.ToPtr("ACUs"), Value: lo.ToPtr("160")}, {Name: lo.ToPtr("vCPUsPerCore"), Value: lo.ToPtr("2")}, {Name: lo.ToPtr("CombinedTempDiskAndCachedIOPS"), Value: lo.ToPtr("3000")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("48234496")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("24117248")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("49152000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("24576000")}, + {Name: lo.ToPtr("UncachedDiskIOPS"), Value: lo.ToPtr("3200")}, + {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("48000000")}, {Name: lo.ToPtr("EphemeralOSDiskSupported"), Value: lo.ToPtr("False")}, {Name: lo.ToPtr("EncryptionAtHostSupported"), Value: lo.ToPtr("False")}, {Name: lo.ToPtr("CapacityReservationSupported"), Value: lo.ToPtr("False")}, @@ -257,11 +351,11 @@ func init() { {Name: lo.ToPtr("VMDeploymentTypes"), Value: lo.ToPtr("IaaS")}, {Name: lo.ToPtr("vCPUsAvailable"), Value: lo.ToPtr("2")}, {Name: lo.ToPtr("vCPUsPerCore"), Value: lo.ToPtr("2")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedIOPS"), Value: lo.ToPtr("19000")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("131072000")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("131072000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedIOPS"), Value: lo.ToPtr("9000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("125000000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("125000000")}, {Name: lo.ToPtr("UncachedDiskIOPS"), Value: lo.ToPtr("3750")}, - {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("89128960")}, + {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("85000000")}, {Name: lo.ToPtr("EphemeralOSDiskSupported"), Value: lo.ToPtr("False")}, {Name: lo.ToPtr("EncryptionAtHostSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("CapacityReservationSupported"), Value: lo.ToPtr("False")}, @@ -288,6 +382,7 @@ func init() { {Name: lo.ToPtr("vCPUs"), Value: lo.ToPtr("4")}, {Name: lo.ToPtr("MemoryPreservingMaintenanceSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("HyperVGenerations"), Value: lo.ToPtr("V1,V2")}, + {Name: lo.ToPtr("SupportedEphemeralOSDiskPlacements"), Value: lo.ToPtr("ResourceDisk,CacheDisk")}, {Name: lo.ToPtr("MemoryGB"), Value: lo.ToPtr("16")}, {Name: lo.ToPtr("MaxDataDiskCount"), Value: lo.ToPtr("8")}, {Name: lo.ToPtr("CpuArchitectureType"), Value: lo.ToPtr("x64")}, @@ -298,11 +393,11 @@ func init() { {Name: lo.ToPtr("ACUs"), Value: lo.ToPtr("160")}, {Name: lo.ToPtr("vCPUsPerCore"), Value: lo.ToPtr("2")}, {Name: lo.ToPtr("CombinedTempDiskAndCachedIOPS"), Value: lo.ToPtr("8000")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("67108864")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("67108864")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("65536000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("65536000")}, {Name: lo.ToPtr("CachedDiskBytes"), Value: lo.ToPtr("107374182400")}, {Name: lo.ToPtr("UncachedDiskIOPS"), Value: lo.ToPtr("6400")}, - {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("100663296")}, + {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("96000000")}, {Name: lo.ToPtr("EphemeralOSDiskSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("EncryptionAtHostSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("CapacityReservationSupported"), Value: lo.ToPtr("False")}, @@ -329,6 +424,7 @@ func init() { {Name: lo.ToPtr("vCPUs"), Value: lo.ToPtr("64")}, {Name: lo.ToPtr("MemoryPreservingMaintenanceSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("HyperVGenerations"), Value: lo.ToPtr("V1,V2")}, + {Name: lo.ToPtr("SupportedEphemeralOSDiskPlacements"), Value: lo.ToPtr("ResourceDisk,CacheDisk")}, {Name: lo.ToPtr("MemoryGB"), Value: lo.ToPtr("256")}, {Name: lo.ToPtr("MaxDataDiskCount"), Value: lo.ToPtr("32")}, {Name: lo.ToPtr("CpuArchitectureType"), Value: lo.ToPtr("x64")}, @@ -339,11 +435,11 @@ func init() { {Name: lo.ToPtr("ACUs"), Value: lo.ToPtr("160")}, {Name: lo.ToPtr("vCPUsPerCore"), Value: lo.ToPtr("2")}, {Name: lo.ToPtr("CombinedTempDiskAndCachedIOPS"), Value: lo.ToPtr("128000")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("1073741824")}, - {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("1073741824")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedReadBytesPerSecond"), Value: lo.ToPtr("1048576000")}, + {Name: lo.ToPtr("CombinedTempDiskAndCachedWriteBytesPerSecond"), Value: lo.ToPtr("1048576000")}, {Name: lo.ToPtr("CachedDiskBytes"), Value: lo.ToPtr("1717986918400")}, {Name: lo.ToPtr("UncachedDiskIOPS"), Value: lo.ToPtr("80000")}, - {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("1258291200")}, + {Name: lo.ToPtr("UncachedDiskBytesPerSecond"), Value: lo.ToPtr("1200000000")}, {Name: lo.ToPtr("EphemeralOSDiskSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("EncryptionAtHostSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("CapacityReservationSupported"), Value: lo.ToPtr("False")}, @@ -370,6 +466,7 @@ func init() { {Name: lo.ToPtr("vCPUs"), Value: lo.ToPtr("2")}, {Name: lo.ToPtr("MemoryPreservingMaintenanceSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("HyperVGenerations"), Value: lo.ToPtr("V1,V2")}, + {Name: lo.ToPtr("SupportedEphemeralOSDiskPlacements"), Value: lo.ToPtr("ResourceDisk,CacheDisk")}, {Name: lo.ToPtr("MemoryGB"), Value: lo.ToPtr("7")}, {Name: lo.ToPtr("MaxDataDiskCount"), Value: lo.ToPtr("8")}, {Name: lo.ToPtr("CpuArchitectureType"), Value: lo.ToPtr("x64")}, @@ -411,6 +508,7 @@ func init() { {Name: lo.ToPtr("vCPUs"), Value: lo.ToPtr("16")}, {Name: lo.ToPtr("MemoryPreservingMaintenanceSupported"), Value: lo.ToPtr("True")}, {Name: lo.ToPtr("HyperVGenerations"), Value: lo.ToPtr("V1,V2")}, + {Name: lo.ToPtr("SupportedEphemeralOSDiskPlacements"), Value: lo.ToPtr("ResourceDisk,CacheDisk")}, {Name: lo.ToPtr("MemoryGB"), Value: lo.ToPtr("32")}, {Name: lo.ToPtr("MaxDataDiskCount"), Value: lo.ToPtr("32")}, {Name: lo.ToPtr("CpuArchitectureType"), Value: lo.ToPtr("x64")}, diff --git a/pkg/providers/instancetype/instancetypes.go b/pkg/providers/instancetype/instancetypes.go index a463bdc3b..f5b400f68 100644 --- a/pkg/providers/instancetype/instancetypes.go +++ b/pkg/providers/instancetype/instancetypes.go @@ -32,6 +32,7 @@ import ( corev1 "k8s.io/api/core/v1" karpv1 "sigs.k8s.io/karpenter/pkg/apis/v1" + "github.com/Azure/azure-sdk-for-go/profiles/latest/compute/mgmt/compute" "github.com/Azure/go-autorest/autorest/to" "github.com/Azure/karpenter-provider-azure/pkg/apis/v1alpha2" kcache "github.com/Azure/karpenter-provider-azure/pkg/cache" @@ -274,7 +275,8 @@ func (p *DefaultProvider) getInstanceTypes(ctx context.Context) (map[string]*ske continue } - if !skus[i].HasLocationRestriction(p.region) && p.isSupported(&skus[i], vmsize) { + useSIG := false // replace with options.FromContext(ctx).UseSIG when available + if !skus[i].HasLocationRestriction(p.region) && p.isSupported(&skus[i], vmsize, useSIG) { instanceTypes[skus[i].GetName()] = &skus[i] } } @@ -291,13 +293,14 @@ func (p *DefaultProvider) getInstanceTypes(ctx context.Context) (map[string]*ske } // isSupported indicates SKU is supported by AKS, based on SKU properties -func (p *DefaultProvider) isSupported(sku *skewer.SKU, vmsize *skewer.VMSizeType) bool { +func (p *DefaultProvider) isSupported(sku *skewer.SKU, vmsize *skewer.VMSizeType, useSIG bool) bool { return p.hasMinimumCPU(sku) && p.hasMinimumMemory(sku) && !p.isUnsupportedByAKS(sku) && !p.isUnsupportedGPU(sku) && !p.hasConstrainedCPUs(vmsize) && - !p.isConfidential(sku) + !p.isConfidential(sku) && + isCompatibleImageAvailable(sku, useSIG) } // at least 2 cpus @@ -406,3 +409,15 @@ var ( func hasZonalSupport(region string) bool { return zonalRegions.Has(region) } + +func isCompatibleImageAvailable(sku *skewer.SKU, useSIG bool) bool { + hasSCSISupport := func(sku *skewer.SKU) bool { // TODO: move capability determination to skewer + const diskControllerTypeCapability = "DiskControllerTypes" + declaresSCSI := sku.HasCapabilityWithSeparator(diskControllerTypeCapability, string(compute.SCSI)) + declaresNVMe := sku.HasCapabilityWithSeparator(diskControllerTypeCapability, string(compute.NVMe)) + declaresNothing := !(declaresSCSI || declaresNVMe) + return declaresSCSI || declaresNothing // if nothing is declared, assume SCSI is supported + } + + return useSIG || hasSCSISupport(sku) // CIG images are not currently tagged for NVMe +} diff --git a/pkg/providers/instancetype/suite_test.go b/pkg/providers/instancetype/suite_test.go index 6c4a5b85c..ce27f1290 100644 --- a/pkg/providers/instancetype/suite_test.go +++ b/pkg/providers/instancetype/suite_test.go @@ -348,6 +348,9 @@ var _ = Describe("InstanceType Provider", func() { It("should not include confidential SKUs", func() { Expect(instanceTypes).ShouldNot(ContainElement(WithTransform(getName, Equal("Standard_DC8s_v3")))) }) + It("should not include SKUs without compatible image", func() { + Expect(instanceTypes).ShouldNot(ContainElement(WithTransform(getName, Equal("Standard_D2as_v6")))) + }) }) Context("Filtering GPU SKUs ProviderList(AzureLinux)", func() { var instanceTypes corecloudprovider.InstanceTypes