Skip to content

chore: support v7 skus in AB e2es#7887

Merged
lilypan26 merged 29 commits intomainfrom
lily/add-vm-size-e2e-pipeline-variable
Feb 26, 2026
Merged

chore: support v7 skus in AB e2es#7887
lilypan26 merged 29 commits intomainfrom
lily/add-vm-size-e2e-pipeline-variable

Conversation

@lilypan26
Copy link
Contributor

@lilypan26 lilypan26 commented Feb 17, 2026

What this PR does / why we need it:
AB e2e adjustments needed to run v7 skus. Primarily:

  • v7 only supports disktype NVMe, we need to set this in vmss model when required
  • v7 only supports gen 2 VMs, we should skip all e2es with gen 1 image

Which issue(s) this PR fixes:

Fixes #

Copilot AI review requested due to automatic review settings February 17, 2026 19:25
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR modifies the e2e test infrastructure to add support for configurable VM size and location variables, and increases timeout values to accommodate longer-running test scenarios. The changes span the e2e configuration, pipeline template, and the e2e run script.

Changes:

  • Increases cluster creation timeout from 20 to 30 minutes in e2e config
  • Doubles the e2e pipeline timeout from 90 to 180 minutes
  • Adds VM_SIZE and LOCATION as optional pipeline variables that can override defaults

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 4 comments.

File Description
e2e/config/config.go Increases TestTimeoutCluster default from 20m to 30m
.pipelines/templates/e2e-template.yaml Doubles timeoutInMinutes from 90 to 180
.pipelines/scripts/e2e_run.sh Adds exports for VM_SIZE→DEFAULT_VM_SKU and LOCATION variables with echo statements for debugging

@lilypan26 lilypan26 changed the title Lily/add vm size e2e pipeline variable chore: vm size as configurable e2e pipeline variable Feb 18, 2026
Copilot AI review requested due to automatic review settings February 19, 2026 07:00
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.

Copilot AI review requested due to automatic review settings February 19, 2026 22:15
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.

Copilot AI review requested due to automatic review settings February 20, 2026 08:19
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 7 out of 7 changed files in this pull request and generated 4 comments.

Copilot AI review requested due to automatic review settings February 25, 2026 00:33
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 6 out of 6 changed files in this pull request and generated 6 comments.

Copilot AI review requested due to automatic review settings February 25, 2026 23:29
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 9 out of 9 changed files in this pull request and generated 4 comments.

Copilot AI review requested due to automatic review settings February 26, 2026 00:40
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 8 out of 8 changed files in this pull request and generated 2 comments.

Comment on lines +272 to +289
gen2Only, err := CachedIsVMSizeGen2Only(ctx, VMSizeSKURequest{
Location: s.Location,
VMSize: config.Config.DefaultVMSKU,
})
require.NoError(s.T, err, "checking if VM size %q supports only Gen2", config.Config.DefaultVMSKU)
if gen2Only && s.Config.VHD.UnsupportedGen2 {
s.T.Logf("VM size %q only supports Gen2 hypervisor but image does not, falling back to vm size that supported gen 1 %q", config.Config.DefaultVMSKU, config.DefaultV5VMSKU)
config.Config.DefaultVMSKU = config.DefaultV5VMSKU
}
supportsNVMe, err := CachedVMSizeSupportsNVMe(ctx, VMSizeSKURequest{
Location: s.Location,
VMSize: config.Config.DefaultVMSKU,
})
require.NoError(s.T, err, "checking if VM size %q supports only NVMe", config.Config.DefaultVMSKU)
if supportsNVMe {
if s.Config.VHD.UnsupportedNVMe {
s.T.Logf("VM size %q supports NVMe disk controller but image does not support NVMe, falling back to vm size that supports SCSI %q", config.Config.DefaultVMSKU, config.DefaultV5VMSKU)
config.Config.DefaultVMSKU = config.DefaultV5VMSKU
Copy link

Copilot AI Feb 26, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This mutates the global config.Config.DefaultVMSKU at runtime. Since RunScenario calls t.Parallel() by default, this introduces a cross-test data race and can cause unrelated scenarios to start using the fallback SKU. It also happens after getBaseNBC / nbcToAKSNodeConfigV1 have already read DefaultVMSKU, so the VM size used in the bootstrapping config can diverge from the VMSS size. Instead, compute an effective VM size as a scenario-local value (e.g., on Scenario/ScenarioRuntime) before building NBC/AKSNodeConfig and VMSS model, and never mutate the global config during test execution.

Suggested change
gen2Only, err := CachedIsVMSizeGen2Only(ctx, VMSizeSKURequest{
Location: s.Location,
VMSize: config.Config.DefaultVMSKU,
})
require.NoError(s.T, err, "checking if VM size %q supports only Gen2", config.Config.DefaultVMSKU)
if gen2Only && s.Config.VHD.UnsupportedGen2 {
s.T.Logf("VM size %q only supports Gen2 hypervisor but image does not, falling back to vm size that supported gen 1 %q", config.Config.DefaultVMSKU, config.DefaultV5VMSKU)
config.Config.DefaultVMSKU = config.DefaultV5VMSKU
}
supportsNVMe, err := CachedVMSizeSupportsNVMe(ctx, VMSizeSKURequest{
Location: s.Location,
VMSize: config.Config.DefaultVMSKU,
})
require.NoError(s.T, err, "checking if VM size %q supports only NVMe", config.Config.DefaultVMSKU)
if supportsNVMe {
if s.Config.VHD.UnsupportedNVMe {
s.T.Logf("VM size %q supports NVMe disk controller but image does not support NVMe, falling back to vm size that supports SCSI %q", config.Config.DefaultVMSKU, config.DefaultV5VMSKU)
config.Config.DefaultVMSKU = config.DefaultV5VMSKU
vmSize := config.Config.DefaultVMSKU
gen2Only, err := CachedIsVMSizeGen2Only(ctx, VMSizeSKURequest{
Location: s.Location,
VMSize: vmSize,
})
require.NoError(s.T, err, "checking if VM size %q supports only Gen2", vmSize)
if gen2Only && s.Config.VHD.UnsupportedGen2 {
s.T.Logf("VM size %q only supports Gen2 hypervisor but image does not, falling back to vm size that supported gen 1 %q", vmSize, config.DefaultV5VMSKU)
vmSize = config.DefaultV5VMSKU
}
supportsNVMe, err := CachedVMSizeSupportsNVMe(ctx, VMSizeSKURequest{
Location: s.Location,
VMSize: vmSize,
})
require.NoError(s.T, err, "checking if VM size %q supports only NVMe", vmSize)
if supportsNVMe {
if s.Config.VHD.UnsupportedNVMe {
s.T.Logf("VM size %q supports NVMe disk controller but image does not support NVMe, falling back to vm size that supports SCSI %q", vmSize, config.DefaultV5VMSKU)
vmSize = config.DefaultV5VMSKU

Copilot uses AI. Check for mistakes.
@lilypan26 lilypan26 merged commit 660118c into main Feb 26, 2026
33 of 35 checks passed
@lilypan26 lilypan26 deleted the lily/add-vm-size-e2e-pipeline-variable branch February 26, 2026 18:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants