Skip to content

[confcom] Add containers from vn2 command#9560

Merged
necusjz merged 9 commits intoAzure:mainfrom
DomAyre:containers-from-vn2
Jan 29, 2026
Merged

[confcom] Add containers from vn2 command#9560
necusjz merged 9 commits intoAzure:mainfrom
DomAyre:containers-from-vn2

Conversation

@DomAyre
Copy link
Copy Markdown
Contributor

@DomAyre DomAyre commented Jan 29, 2026

Why

This command generates a partial container policy based on an input vn2 yaml definition.

How

  • Add new containers from_vn2 command
  • Add testing

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

Related command

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

Copilot AI review requested due to automatic review settings January 29, 2026 08:32
@azure-client-tools-bot-prd
Copy link
Copy Markdown

azure-client-tools-bot-prd bot commented Jan 29, 2026

⚠️Azure CLI Extensions Breaking Change Test
⚠️confcom
rule cmd_name rule_message suggest_message
⚠️ 1013 - SubgroupPropAdd confcom containers sub group confcom containers added property commands

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

Hi @DomAyre,
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
Copy Markdown
Collaborator

yonzhan commented Jan 29, 2026

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

@github-actions
Copy link
Copy Markdown
Contributor

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>

@github-actions
Copy link
Copy Markdown
Contributor

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 adds a new command az confcom containers from_vn2 that generates partial container policy definitions from VN2 (Virtual Node 2) YAML templates. The command processes Kubernetes-style templates and produces security policy container definitions.

Changes:

  • Added new containers from_vn2 command with full parameter support and help text
  • Added comprehensive test coverage with 17 sample scenarios
  • Updated version from 1.6.0 to 1.7.0

Reviewed changes

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

Show a summary per file
File Description
src/confcom/setup.py Version bump to 1.7.0
src/confcom/azext_confcom/command/containers_from_vn2.py Core implementation for VN2 template parsing and conversion
src/confcom/azext_confcom/lib/policy.py Updated data models to use int for signals instead of strings
src/confcom/azext_confcom/lib/platform.py Added VN2-specific constants and configurations
src/confcom/azext_confcom/lib/containers.py Added container merging utility and VN2 platform support
src/confcom/azext_confcom/tests/latest/test_confcom_*.py Comprehensive test coverage for new functionality
src/confcom/samples/vn2/* 17 sample scenarios with expected outputs

Comment thread src/confcom/azext_confcom/lib/platform.py
Comment thread src/confcom/azext_confcom/lib/platform.py
Comment thread src/confcom/azext_confcom/command/containers_from_vn2.py
Comment thread src/confcom/azext_confcom/command/containers_from_vn2.py
@necusjz necusjz merged commit 15e9485 into Azure:main Jan 29, 2026
24 checks passed
@azclibot
Copy link
Copy Markdown
Collaborator

[Release] Update index.json for extension [ confcom ] : https://dev.azure.com/msazure/One/_build/results?buildId=151191933&view=results

jepetty pushed a commit to jepetty/azure-cli-extensions that referenced this pull request Feb 11, 2026
* Add containers from_vn2 command

* Satisfy azdev style and linter checks

* Add some tests

* Add tests for containers from_vn2

* Full testing

* Fix merge conflict

* Fix azdev style

* Support multiple containers
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.

6 participants