Skip to content

Commit

Permalink
Merge pull request #4020 from k8s-infra-cherrypick-robot/cherry-pick-…
Browse files Browse the repository at this point in the history
…4018-to-release-1.11

[release-1.11] Arm64 should be upper cased and a const
  • Loading branch information
k8s-ci-robot authored Sep 20, 2023
2 parents c6918c0 + 9981adf commit 1953a16
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
3 changes: 2 additions & 1 deletion azure/defaults.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ import (
"github.com/Azure/azure-sdk-for-go/sdk/azcore/arm"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/cloud"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/policy"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v5"
"github.com/Azure/go-autorest/autorest"
"sigs.k8s.io/cluster-api-provider-azure/util/tele"
"sigs.k8s.io/cluster-api-provider-azure/version"
Expand Down Expand Up @@ -303,7 +304,7 @@ func GetBootstrappingVMExtension(osType string, cloud string, vmName string, cpu
// Go on Ubuntu 20.04. The issue is being tracked here: https://github.com/golang/go/issues/58550
// TODO: Remove this once the issue is fixed, or when Ubuntu 20.04 is no longer supported.
extensionVersion := "1.0"
if cpuArchitectureType == "arm64" {
if cpuArchitectureType == string(armcompute.ArchitectureTypesArm64) {
extensionVersion = "1.1.1"
}
return &ExtensionSpec{
Expand Down
4 changes: 2 additions & 2 deletions azure/defaults_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -321,11 +321,11 @@ func TestGetBootstrappingVMExtension(t *testing.T) {
expectedVersion: "1.0",
},
{
name: "Linux OS, Public Cloud, arm64 CPU Architecture",
name: "Linux OS, Public Cloud, ARM64 CPU Architecture",
osType: LinuxOS,
cloud: PublicCloudName,
vmName: "test-vm",
cpuArchitecture: "arm64",
cpuArchitecture: "Arm64",
expectedVersion: "1.1.1",
},
{
Expand Down

0 comments on commit 1953a16

Please sign in to comment.