-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
32 additions
and
9 deletions.
There are no files selected for viewing
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,37 @@ | ||
# -------------------------------------------------------------------------------------------- | ||
# -------------------------------------------------------------------------- | ||
# Copyright (c) Microsoft Corporation. All rights reserved. | ||
# Licensed under the MIT License. See License.txt in the project root for license information. | ||
# Licensed under the MIT License. See License.txt in the project root for | ||
# license information. | ||
# | ||
# Code generated by aaz-dev-tools | ||
# -------------------------------------------------------------------------------------------- | ||
|
||
# Code generated by Microsoft (R) AutoRest Code Generator. | ||
# Changes may cause incorrect behavior and will be lost if the code is | ||
# regenerated. | ||
# -------------------------------------------------------------------------- | ||
# pylint: disable=too-many-lines | ||
# pylint: disable=unused-argument | ||
# pylint: disable=too-many-statements | ||
|
||
from knack.log import get_logger | ||
from azure.cli.core.aaz import register_command | ||
from .aaz.latest.arcgateway.settings import Update as _Update | ||
|
||
@register_command( | ||
"arcgateway settings update", | ||
) | ||
class Update(_Update): | ||
"""Update the base Settings of the target resource. | ||
:example: Sample command for setting update | ||
az arcgateway settings update --resource-group myResourceGroup --subscription mySubscription --base-provider Microsoft.HybridCompute --base-resource-type machines --base-resource-name workloadServer --settings-resource-name default --gateway-resource-id myResourceId | ||
""" | ||
@classmethod | ||
def _build_arguments_schema(cls, *args, **kwargs): | ||
args_schema = super()._build_arguments_schema(*args, **kwargs) | ||
|
||
args_schema.settings_resource_name._required = False | ||
args_schema.settings_resource_name._registered = False | ||
|
||
return args_schema | ||
|
||
logger = get_logger(__name__) | ||
def pre_operations(self): | ||
args = self.ctx.args | ||
args.settings_resource_name = "Default" |