Skip to content

Commit

Permalink
Merge branch 'main' into zb/fixCVMBuildCVE
Browse files Browse the repository at this point in the history
  • Loading branch information
Zachary Bailey committed Jan 23, 2025
2 parents b7580de + 38df0e5 commit 5763519
Show file tree
Hide file tree
Showing 138 changed files with 78,999 additions and 18,872 deletions.
16 changes: 16 additions & 0 deletions e2e/scenario_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -976,6 +976,22 @@ func Test_Ubuntu2204_ContainerdURL(t *testing.T) {
})
}

func Test_Ubuntu2204_ContainerdURL_Scriptless(t *testing.T) {
RunScenario(t, &Scenario{
Description: "tests that a node using the Ubuntu 2204 VHD with the ContainerdPackageURL override the provided URL and not the components.json containerd version",
Config: Config{
Cluster: ClusterKubenet,
VHD: config.VHDUbuntu2204Gen2Containerd,
AKSNodeConfigMutator: func(config *aksnodeconfigv1.Configuration) {
config.ContainerdConfig.ContainerdPackageUrl = "https://packages.microsoft.com/ubuntu/22.04/prod/pool/main/m/moby-containerd/moby-containerd_1.6.9+azure-ubuntu22.04u1_amd64.deb"
},
Validator: func(ctx context.Context, s *Scenario) {
ValidateInstalledPackageVersion(ctx, s, "containerd", "1.6.9")
},
},
})
}

func Test_Ubuntu2204_ContainerdHasCurrentVersion(t *testing.T) {
RunScenario(t, &Scenario{
Description: "tests that a node using an Ubuntu2204 VHD and the ContainerdVersion override bootstraps with the correct components.json containerd version and ignores the override",
Expand Down
15 changes: 14 additions & 1 deletion vhdbuilder/packer/configure-windows-vhd.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -78,9 +78,22 @@ function Download-FileWithAzCopy {
pushd "$global:aksTempDir"
$env:AZCOPY_JOB_PLAN_LOCATION="$global:aksTempDir\azcopy"
$env:AZCOPY_LOG_LOCATION="$global:aksTempDir\azcopy"

mkdir -Force $env:AZCOPY_LOG_LOCATION
if (Test-Path -Path "$env:AZCOPY_LOG_LOCATION\*.log" ) {
rm -Force "$env:AZCOPY_LOG_LOCATION\*.log"
}

Write-Log "Logging in to AzCopy"
# user_assigned_managed_identities has been bound in vhdbuilder/packer/windows-vhd-builder-sig.json
.\azcopy.exe login --login-type=MSI
.\azcopy.exe copy $URL $Dest

Write-Log "Copying $URL to $Dest"
.\azcopy.exe copy "$URL" "$Dest"

Write-Log "--- START AzCopy Log"
Get-Content "$env:AZCOPY_LOG_LOCATION\*.log" | Write-Log
Write-Log "--- END AzCopy Log"
popd
}

Expand Down
Loading

0 comments on commit 5763519

Please sign in to comment.