{AKS} Add support for provisioning secondary network interfaces in node pool#9886
{AKS} Add support for provisioning secondary network interfaces in node pool#9886jumpinthefire wants to merge 7 commits into
Conversation
❌Azure CLI Extensions Breaking Change Test
|
|
Hi @jumpinthefire, |
|
Thank you for your contribution! We will review the pull request and get back to you soon. |
|
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). pip install azdev --upgrade
azdev setup -c <your azure-cli repo path> -r <your azure-cli-extensions repo path>
|
There was a problem hiding this comment.
Pull request overview
Adds support for configuring AKS node pool secondary network interfaces through the aks-preview extension, aligning az aks nodepool add with the 2026-03-02-preview AKS API capability.
Changes:
- Adds
--secondary-network-interfaces/--secondary-nicsargument plumbing. - Parses inline JSON or
@fileinput intoAgentPoolNetworkInterfacemodels. - Adds unit and live scenario coverage for inline secondary NIC configuration.
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
src/aks-preview/azext_aks_preview/custom.py |
Adds the new command parameter to aks_agentpool_add. |
src/aks-preview/azext_aks_preview/_params.py |
Registers the new CLI argument and alias. |
src/aks-preview/azext_aks_preview/_help.py |
Documents the new node pool add option. |
src/aks-preview/azext_aks_preview/agentpool_decorator.py |
Parses secondary NIC input and attaches it to the agent pool network profile. |
src/aks-preview/azext_aks_preview/tests/latest/test_agentpool_decorator.py |
Adds unit coverage for default, inline JSON, and non-array input. |
src/aks-preview/azext_aks_preview/tests/latest/test_aks_commands.py |
Adds a live scenario for creating a node pool with secondary NICs. |
|
Release SuggestionsModule: aks-preview
Notes
|
| @AKSCustomResourceGroupPreparer( | ||
| random_name_length=17, name_prefix="clitest", location="eastus" | ||
| ) | ||
| def test_aks_nodepool_add_with_secondary_network_interfaces( |
There was a problem hiding this comment.
Could you please queue a live test run to demonstrate that it can pass?
There was a problem hiding this comment.
I ran a live test locally and it passed (after some adjustments):
⏺ Bash(AZURE_TEST_RUN_LIVE=True python -m pytest azext_aks_preview/tests/latest/test_aks_commands.py -k "test_aks_nodepool_add_with_secondary_network_interfaces" -x 2>…)
⎿ ========== 1 passed, 365 deselected, 12 warnings in 426.83s (0:07:06) ==========
I also added the @live_only decorator but let me know if you'd rather have a recording available.
|
/azp run |
|
Azure Pipelines successfully started running 2 pipeline(s). |
|
/azp run |
|
Commenter does not have sufficient privileges for PR 9886 in repo Azure/azure-cli-extensions |
The 2026-03-02 preview version of the AKS API now allows provisioning secondary network interfaces within a node pool. This PR adds the
--secondary-network-interfacesargument toaz aks nodepool addto supply a JSON array (either inline or via file) to provision secondary NICs.This checklist is used to make sure that common guidelines for a pull request are followed.
Related command
General Guidelines
azdev style <YOUR_EXT>locally? (pip install azdevrequired)python scripts/ci/test_index.py -qlocally? (pip install wheel==0.30.0required)For new extensions:
About Extension Publish
There is a pipeline to automatically build, upload and publish extension wheels.
Once your pull request is merged into main branch, a new pull request will be created to update
src/index.jsonautomatically.You only need to update the version information in file setup.py and historical information in file HISTORY.rst in your PR but do not modify
src/index.json.