-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Enable ssh connectivity for dev sku #8856
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
Conversation
️✔️Azure CLI Extensions Breaking Change Test
|
|
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>
|
|
Thank you for your contribution! We will review the pull request and get back to you soon. |
There was a problem hiding this 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 extension version, adds a release note, and refactors SSH bastion logic to support Developer SKU native client connectivity.
- Bump extension version to 1.4.1 and add HISTORY entry
- Introduce
_is_nativeclient_enabledhelper and replace SKU/tunneling check - Update error path to use new helper
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| src/bastion/setup.py | Updated VERSION to 1.4.1 |
| src/bastion/azext_bastion/custom.py | Added _is_nativeclient_enabled, refactored SKU/tunneling check |
| src/bastion/HISTORY.rst | Added 1.4.1 release notes |
Comments suppressed due to low confidence (3)
src/bastion/azext_bastion/custom.py:184
- The error message is now misleading because Developer SKU is allowed. Update it to reflect that Developer, Standard, or Premium SKUs are supported when native client (tunneling) is enabled.
raise ClientRequestError('Bastion Host SKU must be Standard or Premium and Native Client must be enabled.')
src/bastion/azext_bastion/custom.py:391
- Add a docstring for
_is_nativeclient_enabledto explain when it returns true (e.g., Developer SKU always, Standard/Premium with tunneling).
def _is_nativeclient_enabled(bastion):
src/bastion/azext_bastion/custom.py:183
- Consider adding unit tests for
_is_nativeclient_enabledand for the SSH flow with Developer SKU to ensure correct connectivity behavior.
if not _is_nativeclient_enabled(bastion):
CodeGen Tools Feedback CollectionThank you for using our CodeGen tool. We value your feedback, and we would like to know how we can improve our product. Please take a few minutes to fill our codegen survey |
|
|
/azp run |
|
Azure Pipelines successfully started running 2 pipeline(s). |
|
/azp run |
|
Commenter does not have sufficient privileges for PR 8856 in repo Azure/azure-cli-extensions |
|
/azp run |
|
Commenter does not have sufficient privileges for PR 8856 in repo Azure/azure-cli-extensions |
|
/azp run |
|
Azure Pipelines successfully started running 2 pipeline(s). |
|
[Release] Update index.json for extension [ bastion-1.4.1 ] : https://dev.azure.com/msazure/One/_build/results?buildId=127151782&view=results |
This PR enables SSH connectivity for the Developer SKU by replacing the direct SKU and tunneling check with a unified helper function.
Introduce _is_nativeclient_enabled to allow Developer SKU by default and preserve existing checks for Standard/Premium.
Replace the original SKU-plus-tunneling conditional with a call to the new helper.
Retain the error-raising logic, now backed by the helper function.
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.