-
Notifications
You must be signed in to change notification settings - Fork 667
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
[sonic-package-manager] support sonic-cli-gen and packages with YANG model #1650
Conversation
Signed-off-by: Stepan Blyshchak <stepanb@nvidia.com>
Signed-off-by: Stepan Blyshchak <stepanb@nvidia.com>
Signed-off-by: Stepan Blyshchak <stepanb@nvidia.com>
Signed-off-by: Stepan Blyshchak <stepanb@nvidia.com>
…packages-migration
Signed-off-by: Stepan Blyshchak <stepanb@nvidia.com>
…packages-migration Signed-off-by: Stepan Blyschak <stepanb@nvidia.com>
Signed-off-by: Stepan Blyschak <stepanb@nvidia.com>
Signed-off-by: Stepan Blyschak <stepanb@nvidia.com>
Signed-off-by: Stepan Blyschak <stepanb@nvidia.com>
Signed-off-by: Stepan Blyschak <stepanb@nvidia.com>
Signed-off-by: Stepan Blyschak <stepanb@nvidia.com>
Signed-off-by: Stepan Blyschak <stepanb@nvidia.com>
Signed-off-by: Stepan Blyschak <stepanb@nvidia.com>
Signed-off-by: Stepan Blyschak <stepanb@nvidia.com>
Signed-off-by: Stepan Blyschak <stepanb@nvidia.com>
Signed-off-by: Stepan Blyschak <stepanb@nvidia.com>
Signed-off-by: Stepan Blyschak <stepanb@nvidia.com>
Signed-off-by: Stepan Blyschak <stepanb@nvidia.com>
Co-authored-by: Joe LeVeque <jleveque@users.noreply.github.com>
Signed-off-by: Stepan Blyschak <stepanb@nvidia.com>
Signed-off-by: Stepan Blyschak <stepanb@nvidia.com>
Signed-off-by: Stepan Blyschak <stepanb@nvidia.com>
Signed-off-by: Stepan Blyschak <stepanb@nvidia.com>
Signed-off-by: Stepan Blyschak <stepanb@nvidia.com>
Signed-off-by: Stepan Blyschak <stepanb@nvidia.com>
@praveen-li Could you please also review? |
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.
Looks good to me. Just added few minor comments only.
We could merge upon approval by @praveen-li
@praveen-li , @renukamanavalan - do you approve this PR or anything pending? Thanks. |
Signed-off-by: Stepan Blyshchak <stepanb@nvidia.com>
This pull request introduces 1 alert when merging bf05d42 into e7535ae - view on LGTM.com new alerts:
|
Signed-off-by: Stepan Blyshchak <stepanb@nvidia.com>
@renukamanavalan - completed review -- good to merge |
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.
Waiting for Praveen's approval
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.
Thanks for explaining it to me in meeting. I specially reviewed changes in ConfigMgmt. LGTM overall.
module_name = self.get_module_name(yang_module_str) | ||
module_path = os.path.join(YANG_DIR, '{}.yang'.format(module_name)) | ||
if os.path.exists(module_path): | ||
raise Exception('{} already exists'.format(module_name)) |
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.
caller of add_module should be able to handle it gracefully.
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.
The caller can catch the exception and handle it gracefully.
…model (#1650) - What I did This PR brings in support for packages with YANG models and CLI auto generation capabilities for 3rd party packages. - How I did it Packages can set two new flags in manifest - "auto-generate-show" and "auto-generate-config" in addition to YANG module recorded in package image label "com.azure.sonic.yang-module". - How to verify it Build and run. Prepare some package with YANG model and test CLI is generated for it. Signed-off-by: Stepan Blyshchak <stepanb@nvidia.com> Co-authored-by: Vadym Hlushko <vadymh@nvidia.com>
…th YANG model (sonic-net#1650)" This reverts commit f5e5a56.
…kages with YANG model (sonic-net#1650)" (sonic-net#1972)" This reverts commit fe00bbf.
…kages with YANG model (sonic-net#1650)" (sonic-net#1972)" This reverts commit fe00bbf.
…kages with YANG model (#1650)" (#1972)" (#1994) This reverts commit fe00bbf. - What I did Revert previous revert, since the proposed fix has been merged - sonic-net/sonic-buildimage#9587 - How I did it Revert the revert. - How to verify it Run build an on the switch.
…kages with YANG model (#1650)" (#1972)" (#1994) This reverts commit fe00bbf. - What I did Revert previous revert, since the proposed fix has been merged - sonic-net/sonic-buildimage#9587 - How I did it Revert the revert. - How to verify it Run build an on the switch.
…kages with YANG model (sonic-net#1650)" (sonic-net#1972)" (sonic-net#1994) This reverts commit fe00bbf. - What I did Revert previous revert, since the proposed fix has been merged - sonic-net/sonic-buildimage#9587 - How I did it Revert the revert. - How to verify it Run build an on the switch.
NOTE: DEPENDS ON #1644
What I did
This PR brings in support for packages with YANG models and CLI auto generation capabilities for 3rd party packages.
How I did it
Packages can set two new flags in manifest - "auto-generate-show" and "auto-generate-config" in addition to YANG module recorded in package image label "com.azure.sonic.yang-module".
How to verify it
Build and run. Prepare some package with YANG model and test CLI is generated for it.
Previous command output (if the output of a command-line utility has changed)
New command output (if the output of a command-line utility has changed)