Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding the cli command option for --pod-ip-allocation-mode for cluster creation and nodepool addition in AKS #7288

Merged
merged 34 commits into from
Feb 29, 2024

Conversation

nairashu
Copy link
Contributor


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

Related command

az aks create -g MyResourceGroup -n MyManagedCluster --os-sku Ubuntu --max-pods MaxPodsPerNode --network-plugin azure --vnet-subnet-id /subscriptions/00000/resourceGroups/AnotherResourceGroup/providers/Microsoft.Network/virtualNetworks/MyVnet/subnets/NodeSubnet --pod-subnet-id /subscriptions/00000/resourceGroups/AnotherResourceGroup/providers/Microsoft.Network/virtualNetworks/MyVnet/subnets/PodSubnet --pod-ip-allocation-mode StaticBlock

General Guidelines

  • Have you run azdev style <YOUR_EXT> locally? (pip install azdev required)
  • Have you run python scripts/ci/test_index.py -q locally? (pip install wheel==0.30.0 required)
  • My extension version conforms to the Extension version schema

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.json automatically.
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.

Copy link

azure-client-tools-bot-prd bot commented Feb 14, 2024

❌Azure CLI Extensions Breaking Change Test
❌aks-preview
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
⚠️ 1006 - ParaAdd aks create cmd aks create added parameter pod_ip_allocation_mode
⚠️ 1006 - ParaAdd aks nodepool add cmd aks nodepool add added parameter pod_ip_allocation_mode

Copy link

Hi @nairashu,
Please write the description of changes which can be perceived by customers into HISTORY.rst.
If you want to release a new extension version, please update the version in setup.py as well.

@yonzhan
Copy link
Collaborator

yonzhan commented Feb 14, 2024

WIP

@nairashu nairashu changed the title [WIP]: Adding the cli command option for --pod-ip-allocation-mode for cluster creation and nodepool addition in AKS Adding the cli command option for --pod-ip-allocation-mode for cluster creation and nodepool addition in AKS Feb 15, 2024
@nairashu
Copy link
Contributor Author

WIP

Removed the WIP after adding all the changes for this agentpool option.

@nairashu
Copy link
Contributor Author

This PR is a placeholder and waiting on this property to get released in the SDK. Requesting early feedback.

Copy link
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.

Please add some unit test cases (see examples in test_agentpool_decorator.py) and at least one live test case (see examples in test_aks_commands.py) for the newly added option.

Copy link
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.

Please resolve merge conflicts

@nairashu
Copy link
Contributor Author

Please add some unit test cases (see examples in test_agentpool_decorator.py) and at least one live test case (see examples in test_aks_commands.py) for the newly added option.

I have added the requested UT and live test case.

Copy link
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.

Please fix failed UT

FAILED src/aks-preview/azext_aks_preview/tests/latest/test_agentpool_decorator.py::AKSPreviewAgentPoolContextStandaloneModeTestCase::test_get_pod_ip_allocation_mode
FAILED src/aks-preview/azext_aks_preview/tests/latest/test_agentpool_decorator.py::AKSPreviewAgentPoolContextManagedClusterModeTestCase::test_get_pod_ip_allocation_mode

@nairashu
Copy link
Contributor Author

Please resolve merge conflicts

Merge conflicts were resolved

@yonzhan
Copy link
Collaborator

yonzhan commented Feb 21, 2024

Please fix CI issues

@azclibot
Copy link
Collaborator

⚠️ Suggestions

Module: aks-preview

  • Update version to 1.0.0b7 in setup.py
  • Set azext.isPreview to true in azext_aks-preview/azext_metadata.json

Notes

  • Stable/preview tag is inherited from last release. If needed, please add stable/preview label to modify it.
  • Major/minor/patch/pre increment of version number is calculated by pull request code changes automatically. If needed, please add major/minor/patch/pre label to adjust it.
  • For more info about extension versioning, please refer to Extension version schema

Ashish Nair added 21 commits February 29, 2024 04:01
…d then attach an agentpool with StaticBlock
…rk profile which was what was failing the CI
…entpool to both the create and update methods
…he get method for the pod-ip-allocation-mode property and also removed the definition and call to set the property in the AgentPoolUpdateDecorator as the property option is only available in the aks create and aks nodepool add commands.
nairashu and others added 2 commits February 28, 2024 20:09
…ted change

Co-authored-by: Xing Zhou <Zhou.Xing@microsoft.com>
… voice.

Co-authored-by: Xing Zhou <Zhou.Xing@microsoft.com>
@wangzelin007 wangzelin007 merged commit c4eaa7d into Azure:main Feb 29, 2024
13 of 15 checks passed
@azclibot
Copy link
Collaborator

[Release] Update index.json for extension [ aks-preview ] : https://dev.azure.com/azclitools/internal/_build/results?buildId=135128&view=results

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

9 participants