-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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
[ARM] az ts: Add new commands for template specs ; [ARM] az deployment : Add support for --template-spec -s #14448
Merged
zhoxing-ms
merged 173 commits into
Azure:dev
from
detienne20:daetienn/template-spec-crud
Sep 24, 2020
Merged
[ARM] az ts: Add new commands for template specs ; [ARM] az deployment : Add support for --template-spec -s #14448
zhoxing-ms
merged 173 commits into
Azure:dev
from
detienne20:daetienn/template-spec-crud
Sep 24, 2020
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…e stamp added to deployment_name, excess file removed in commit, launch,json reverted
Juliehzl
reviewed
Sep 22, 2020
Juliehzl
reviewed
Sep 22, 2020
jiasli
approved these changes
Sep 22, 2020
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.
Core LGTM.
Juliehzl
reviewed
Sep 22, 2020
Juliehzl
reviewed
Sep 22, 2020
…CE_TEMPLATESPECS before 2019-06-01-preview, so that the judgment logic of min_api is based on ResourceType.MGMT_RESOURCE_TEMPLATESPECS. as requested
detienne20
commented
Sep 24, 2020
detienne20
commented
Sep 24, 2020
detienne20
commented
Sep 24, 2020
Juliehzl
approved these changes
Sep 24, 2020
jsntcy
approved these changes
Sep 24, 2020
Juliehzl
pushed a commit
to Juliehzl/azure-cli
that referenced
this pull request
Sep 30, 2020
…t : Add support for --template-spec -s (Azure#14448) * {Docs} Remove stale reference in README to closed issue about extensions (Azure#12771) * Preliminary changes made to add support for template-specs * Reconfiguration * validate function error rectified * validate command works for template-uri * Template-specs deployment works at resource-group level * Group deployment updated to function with 2020 SDK * validate with template specs added * Management scope and tenant scope errors fixed * Template-Specs Deployment Added * Template-Specs Deployment Added * Updated test cases and removed unnecessary comments * Removed test cases from launch.json * Uncommented test case * Cleaned up repo * Cleaned up repo * Style checks complete, template_spec parameter placed at the end, time stamp added to deployment_name, excess file removed in commit, launch,json reverted * Fixed failing CLI Check Test * Merged with /dev * Added template-specs command group, added help * Create or update template spec functioning * packing engine packing mechanism complete * Template-Specs CRUD Implemented, Artifacts has full support, added test cases and testing files * Updated template-specs CRUD tests and template-specs deployment-tests * Updated all tests for template-specs * Updated tests * Fixed style and linter * Uncommented test case * Fixed linter resource: * merged with dev * merged * Fixed merge errors * Fixed json parsing errors * Revert changed deployment name * Revert changed deployment name * deleted extra deployment object causing bot error * Revered launch.json changes * Removed unnecessary changes * Reinstalled requirements, fixed resource linter and style * Update src/azure-cli/azure/cli/command_modules/resource/_help.py Co-authored-by: Xing Zhou <[email protected]> * Update src/azure-cli/azure/cli/command_modules/resource/_help.py Co-authored-by: Xing Zhou <[email protected]> * Update src/azure-cli/azure/cli/command_modules/resource/_validators.py Co-authored-by: Xing Zhou <[email protected]> * Update src/azure-cli/azure/cli/command_modules/resource/_help.py Co-authored-by: Xing Zhou <[email protected]> * Update src/azure-cli/azure/cli/command_modules/resource/_help.py Co-authored-by: Xing Zhou <[email protected]> * Update src/azure-cli/azure/cli/command_modules/resource/_help.py Co-authored-by: Xing Zhou <[email protected]> * Small syntax suggested by reviewers made * Removed unnecessary changes in test_resource * Merged recordings * Changed python path in launch.json * recorded deployment tests for template-specs * Recorded template-specs CRUD * TemplateSpecs is a live test * Tests are updated to latest * Commands now work with 10.1.0 * Updated what if parameters * Fixed style and linter * acs tests restored * Removed unnecessary changes * Restored launch.json * added git ignore back in * Bot_template restored * removed unnecessary comment * Updated web app folderto new one * revereted * Syntax changes for function names in packing_engine * launch.json issue * changed to new sdk release * Update src/azure-cli/azure/cli/command_modules/resource/_help.py Co-authored-by: Shenglong Li <[email protected]> * Update src/azure-cli/azure/cli/command_modules/resource/_help.py Co-authored-by: Shenglong Li <[email protected]> * Made recommended changes * snake_case for _packing_engine * Restored network tests * Fixed CLI Linter * Small syntax errors fixed * reverted launch.json changes * Deleted local context file * Updated get template-specs * Updated get template-specs * changed validator logic, added tests for template-specs list, changed get template-specs to show template-specs, updated help commands, removed tag commands * changed validator * Fixed validators * Fix getting resource API version in ARM cmdlt Latest swagger updates added the 'defaultApiVersion' property to the GET resource providers response. The old code was trying to use the default API version and only than fall back to the API versions specified in the manifest. This was wrong because: 1. default API version was not part of the response (until the latest SDK update), so this code was not doing anything 2. default API versions can be null 3. default API version is mostly used for internal purposes and must be included in the list of available API versions. This change address this issue. * Changed validators, added what_if test for template_specs * Fixed linter and style resource * Update sample_policy_set.json * Update sample_policy_set.json * Update sample_policy_set_parameterized.json * Allows string for --template-spec parameter * template-spec validators updated * Better error handling for deployment * merged with dev, updated template-specs command module name to ts * Fixed style * Added temporary fix for preview message bug for private preview * Different bug fix attempt * Removed unnecessary changes in preparation for merge * Update src/azure-cli-core/azure/cli/core/commands/__init__.py Co-authored-by: Jiashuo Li <[email protected]> * restored new line at end of files * restored new line at end of files * restored no new line at end of files * restored no new line at end of files * min_api added * Template Specs no longer a live test * New build for recent changes committed to dev * Resource type for template specs changed to profiel type * Export template specs is a live scenario test * restored launch.json * restored launch.json * removed export test folder * Reduced repetitive code in _help.py * Fixed trailing white spaces and added new line at end of _params.py * set a default version in other profiles for ResourceType.MGMT_RESOURCE_TEMPLATESPECS before 2019-06-01-preview, so that the judgment logic of min_api is based on ResourceType.MGMT_RESOURCE_TEMPLATESPECS. as requested * Update launch.json Co-authored-by: Daniel Miller <[email protected]> Co-authored-by: Azure CLI Team <[email protected]> Co-authored-by: Dania Etienne <[email protected]> Co-authored-by: Xing Zhou <[email protected]> Co-authored-by: Shenglong Li <[email protected]> Co-authored-by: Elad Perets <[email protected]> Co-authored-by: Jiashuo Li <[email protected]>
3 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
This PR enables template specs (ts) commands to create, update, list, show, export, and delete template specs. Also added is support for template-specs with Az CLI Deployment. Microsoft.Resources is updated to use the latest Python SDK. The latest Python SDK required some functions to take in different parameters and account for different return types. All test cases involving template-spec have been updated (i.e--template-specs are now created dynamically for az deployment tests).
Note: #14241 has been closed. This PR would include/override the changes made there.
Testing Guide
az ts
Create:
Update:
Show:
List:
Export:
Delete:
Az Deployments with --template-spec
Resource Group:
Subscription Scope:
Management Group:
Tenant-Scope:
History Notes