Skip to content

{AKS} Add Windows2025 OS SKU support for az aks nodepool add#33246

Open
sinmentis wants to merge 1 commit intoAzure:devfrom
sinmentis:shun/aks-ossku-windows2025
Open

{AKS} Add Windows2025 OS SKU support for az aks nodepool add#33246
sinmentis wants to merge 1 commit intoAzure:devfrom
sinmentis:shun/aks-ossku-windows2025

Conversation

@sinmentis
Copy link
Copy Markdown

@sinmentis sinmentis commented Apr 22, 2026

Related command
az aks nodepool add

Description
Exposes the Windows2025 value in the --os-sku enum for az aks nodepool add, resolving AB#37629980.

The azure-mgmt-containerservice SDK (API version 2026-02-01, vendored in #33223) already defines OSSKU.WINDOWS2025, and the
aks-preview extension already supports this value. Today, running the following against the GA CLI fails with an argument validation
error even though the service and SDK support it:

az aks nodepool add -g $RG --cluster-name $CLUSTER -n npwin \
    --node-count 1 --os-type Windows --os-sku Windows2025 \
    --enable-fips-image \
    --aks-custom-headers AKSHTTPCustomFeatures=Microsoft.ContainerService/AKSWindows2025Preview
# az aks nodepool add: 'Windows2025' is not a valid value for '--os-sku'.

Changes:

  • Add CONST_OS_SKU_WINDOWS2025 constant in _consts.py.
  • Append Windows2025 to the node_os_skus enum list used by az aks nodepool add in _params.py. Not added to node_os_skus_create or
    node_os_skus_update, matching the existing Windows2019 / Windows2022 pattern (Windows SKUs are only valid on nodepool add).
  • Update the --os-sku short-summary in _help.py.
  • Add scenario test test_aks_nodepool_add_with_ossku_windows2025 with live recording. The test requires --enable-fips-image because the
    service enforces WindowsVersionCannotDisableFIPS — "FIPS cannot be disabled in Windows '2025' and later".

No SDK bump needed; no breaking changes (additive enum value only).

Testing Guide
Recorded live against a subscription with the Microsoft.ContainerService/AKSWindows2025Preview feature registered, then
verified in playback:

 # live (recording)
 azdev test acs --live -a "-k test_aks_nodepool_add_with_ossku_windows2025"
 # => 1 passed in 996.54s
 
 # playback (what CI runs)
 azdev test acs -a "-k test_aks_nodepool_add_with_ossku_windows2025"
 # => 1 passed in 9.98s
 
 azdev style acs        # PASSED
 azdev linter acs       # PASSED

Manual smoke test:

 az aks nodepool add -g $RG --cluster-name $CLUSTER -n npwin \
     --node-count 1 --os-type Windows --os-sku Windows2025 \
     --enable-fips-image \
     --aks-custom-headers AKSHTTPCustomFeatures=Microsoft.ContainerService/AKSWindows2025Preview

History Notes
[AKS] az aks nodepool add: Add Windows2025 as a supported value for --os-sku


This checklist is used to make sure that common guidelines for a pull request are followed.

Copilot AI review requested due to automatic review settings April 22, 2026 20:57
@azure-client-tools-bot-prd
Copy link
Copy Markdown

azure-client-tools-bot-prd Bot commented Apr 22, 2026

️✔️AzureCLI-FullTest
️✔️acr
️✔️latest
️✔️3.12
️✔️3.13
️✔️acs
️✔️latest
️✔️3.12
️✔️3.13
️✔️advisor
️✔️latest
️✔️3.12
️✔️3.13
️✔️ams
️✔️latest
️✔️3.12
️✔️3.13
️✔️apim
️✔️latest
️✔️3.12
️✔️3.13
️✔️appconfig
️✔️latest
️✔️3.12
️✔️3.13
️✔️appservice
️✔️latest
️✔️3.12
️✔️3.13
️✔️aro
️✔️latest
️✔️3.12
️✔️3.13
️✔️backup
️✔️latest
️✔️3.12
️✔️3.13
️✔️batch
️✔️latest
️✔️3.12
️✔️3.13
️✔️batchai
️✔️latest
️✔️3.12
️✔️3.13
️✔️billing
️✔️latest
️✔️3.12
️✔️3.13
️✔️botservice
️✔️latest
️✔️3.12
️✔️3.13
️✔️cdn
️✔️latest
️✔️3.12
️✔️3.13
️✔️cloud
️✔️latest
️✔️3.12
️✔️3.13
️✔️cognitiveservices
️✔️latest
️✔️3.12
️✔️3.13
️✔️compute_recommender
️✔️latest
️✔️3.12
️✔️3.13
️✔️computefleet
️✔️latest
️✔️3.12
️✔️3.13
️✔️config
️✔️latest
️✔️3.12
️✔️3.13
️✔️configure
️✔️latest
️✔️3.12
️✔️3.13
️✔️consumption
️✔️latest
️✔️3.12
️✔️3.13
️✔️container
️✔️latest
️✔️3.12
️✔️3.13
️✔️containerapp
️✔️latest
️✔️3.12
️✔️3.13
️✔️core
️✔️latest
️✔️3.12
️✔️3.13
️✔️cosmosdb
️✔️latest
️✔️3.12
️✔️3.13
️✔️databoxedge
️✔️latest
️✔️3.12
️✔️3.13
️✔️dls
️✔️latest
️✔️3.12
️✔️3.13
️✔️dms
️✔️latest
️✔️3.12
️✔️3.13
️✔️eventgrid
️✔️latest
️✔️3.12
️✔️3.13
️✔️eventhubs
️✔️latest
️✔️3.12
️✔️3.13
️✔️feedback
️✔️latest
️✔️3.12
️✔️3.13
️✔️find
️✔️latest
️✔️3.12
️✔️3.13
️✔️hdinsight
️✔️latest
️✔️3.12
️✔️3.13
️✔️identity
️✔️latest
️✔️3.12
️✔️3.13
️✔️iot
️✔️latest
️✔️3.12
️✔️3.13
️✔️keyvault
️✔️latest
️✔️3.12
️✔️3.13
️✔️lab
️✔️latest
️✔️3.12
️✔️3.13
️✔️managedservices
️✔️latest
️✔️3.12
️✔️3.13
️✔️maps
️✔️latest
️✔️3.12
️✔️3.13
️✔️marketplaceordering
️✔️latest
️✔️3.12
️✔️3.13
️✔️monitor
️✔️latest
️✔️3.12
️✔️3.13
️✔️mysql
️✔️latest
️✔️3.12
️✔️3.13
️✔️netappfiles
️✔️latest
️✔️3.12
️✔️3.13
️✔️network
️✔️latest
️✔️3.12
️✔️3.13
️✔️policyinsights
️✔️latest
️✔️3.12
️✔️3.13
️✔️postgresql
️✔️latest
️✔️3.12
️✔️3.13
️✔️privatedns
️✔️latest
️✔️3.12
️✔️3.13
️✔️profile
️✔️latest
️✔️3.12
️✔️3.13
️✔️rdbms
️✔️latest
️✔️3.12
️✔️3.13
️✔️redis
️✔️latest
️✔️3.12
️✔️3.13
️✔️relay
️✔️latest
️✔️3.12
️✔️3.13
️✔️resource
️✔️latest
️✔️3.12
️✔️3.13
️✔️role
️✔️latest
️✔️3.12
️✔️3.13
️✔️search
️✔️latest
️✔️3.12
️✔️3.13
️✔️security
️✔️latest
️✔️3.12
️✔️3.13
️✔️servicebus
️✔️latest
️✔️3.12
️✔️3.13
️✔️serviceconnector
️✔️latest
️✔️3.12
️✔️3.13
️✔️servicefabric
️✔️latest
️✔️3.12
️✔️3.13
️✔️signalr
️✔️latest
️✔️3.12
️✔️3.13
️✔️sql
️✔️latest
️✔️3.12
️✔️3.13
️✔️sqlvm
️✔️latest
️✔️3.12
️✔️3.13
️✔️storage
️✔️latest
️✔️3.12
️✔️3.13
️✔️synapse
️✔️latest
️✔️3.12
️✔️3.13
️✔️telemetry
️✔️latest
️✔️3.12
️✔️3.13
️✔️util
️✔️latest
️✔️3.12
️✔️3.13
️✔️vm
️✔️latest
️✔️3.12
️✔️3.13

@azure-client-tools-bot-prd
Copy link
Copy Markdown

Hi @sinmentis,
Since the current milestone time is less than 7 days, this pr will be reviewed in the next milestone.

@azure-client-tools-bot-prd
Copy link
Copy Markdown

azure-client-tools-bot-prd Bot commented Apr 22, 2026

❌AzureCLI-BreakingChangeTest
❌acs
rule cmd_name rule_message suggest_message
1010 - ParaPropUpdate aks nodepool add cmd aks nodepool add update parameter spot_max_price: updated property default from nan to nan please change property default from nan to nan for parameter spot_max_price of cmd aks nodepool add
⚠️ 1010 - ParaPropUpdate aks nodepool add cmd aks nodepool add update parameter os_sku: updated property choices from ['AzureContainerLinux', 'AzureLinux', 'AzureLinux3', 'CBLMariner', 'Mariner', 'Ubuntu', 'Ubuntu2204', 'Ubuntu2404', 'Windows2019', 'Windows2022'] to ['AzureContainerLinux', 'AzureLinux', 'AzureLinux3', 'CBLMariner', 'Mariner', 'Ubuntu', 'Ubuntu2204', 'Ubuntu2404', 'Windows2019', 'Windows2022', 'Windows2025']

Please submit your Breaking Change Pre-announcement ASAP if you haven't already. Please note:

  • Breaking changes can only be merged during the designated breaking change window
  • A pre-announcement must be released at least one month in advance

For more details on how to introduce breaking changes, refer to the documentation: azure-cli/doc/how_to_introduce_breaking_changes.md

@yonzhan
Copy link
Copy Markdown
Collaborator

yonzhan commented Apr 22, 2026

Thank you for your contribution! We will review the pull request and get back to you soon.

@github-actions
Copy link
Copy Markdown

The git hooks are available for azure-cli and azure-cli-extensions repos. They could help you run required checks before creating the PR.

Please sync the latest code with latest dev branch (for azure-cli) or main branch (for azure-cli-extensions).
After that please run the following commands to enable git hooks:

pip install azdev --upgrade
azdev setup -c <your azure-cli repo path> -r <your azure-cli-extensions repo path>

Copy link
Copy Markdown
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 updates the AKS command module to accept Windows2025 as a valid --os-sku for az aks nodepool add, aligning GA CLI behavior with the already-vendored azure-mgmt-containerservice API version 2026-02-01 and the aks-preview extension.

Changes:

  • Add CONST_OS_SKU_WINDOWS2025 and include it in the aks nodepool add --os-sku enum.
  • Update help text for --os-sku to mention Windows2025.
  • Add a scenario test + recording for adding a Windows2025 nodepool (with --enable-fips-image).

Reviewed changes

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

File Description
src/azure-cli/azure/cli/command_modules/acs/_consts.py Adds the Windows2025 OS SKU constant.
src/azure-cli/azure/cli/command_modules/acs/_params.py Extends the --os-sku enum for aks nodepool add to include Windows2025.
src/azure-cli/azure/cli/command_modules/acs/_help.py Updates parameter help text to document Windows2025 support.
src/azure-cli/azure/cli/command_modules/acs/tests/latest/test_aks_commands.py Adds a scenario test for --os-sku Windows2025 nodepool add.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/azure-cli/azure/cli/command_modules/acs/_params.py
@sinmentis
Copy link
Copy Markdown
Author

@sinmentis please read the following Contributor License Agreement(CLA). If you agree with the CLA, please reply with the following information.

@microsoft-github-policy-service agree [company="{your company}"]

Options:

  • (default - no company specified) I have sole ownership of intellectual property rights to my Submissions and I am not making Submissions in the course of work for my employer.
@microsoft-github-policy-service agree
  • (when company given) I am making Submissions in the course of work for my employer (or my employer has intellectual property rights in my Submissions by contract or applicable law). I have permission from my employer to make Submissions and enter into this Agreement on behalf of my employer. By signing below, the defined term “You” includes me and my employer.
@microsoft-github-policy-service agree company="Microsoft"

Contributor License Agreement

@microsoft-github-policy-service agree company="Microsoft"

- Add CONST_OS_SKU_WINDOWS2025 constant
- Append Windows2025 to the node_os_skus enum list used by
  `az aks nodepool add` (not added to create/update lists, mirroring
  the existing Windows2019/2022 behavior)
- Update --os-sku help text
- Add scenario test test_aks_nodepool_add_with_ossku_windows2025,
  including live recording. Windows2025 requires FIPS enabled, so the
  test uses --enable-fips-image and asserts enableFips=True

AB#37629980
Copy link
Copy Markdown
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 7 changed files in this pull request and generated no new comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link
Copy Markdown

@timmy-wright timmy-wright left a comment

Choose a reason for hiding this comment

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

I had a look at this - one comment by copilot that seems worth addressing. And probably worth thinking if there's a refactor so that there's one list of windows SKUs that's used by all other things - then when we add WS2018 and other windows versions, the PR will be smaller.

@FumingZhang
Copy link
Copy Markdown
Member

/azp run

@azure-pipelines
Copy link
Copy Markdown

Azure Pipelines successfully started running 3 pipeline(s).

Copy link
Copy Markdown
Member

@FumingZhang FumingZhang left a comment

Choose a reason for hiding this comment

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

lgtm

@sinmentis
Copy link
Copy Markdown
Author

/azp run

@azure-pipelines
Copy link
Copy Markdown

Commenter does not have sufficient privileges for PR 33246 in repo Azure/azure-cli

@sinmentis sinmentis requested a review from FumingZhang April 23, 2026 21:17
@FumingZhang
Copy link
Copy Markdown
Member

/azp run

@azure-pipelines
Copy link
Copy Markdown

Azure Pipelines successfully started running 3 pipeline(s).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

act-observability-squad AKS az aks/acs/openshift Auto-Assign Auto assign by bot

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants