Skip to content

Commit 2f247de

Browse files
author
SDK Automation
committed
Generated from 015e3c7a98188544cbab58f3d9a5f7b4f8c0ca5f
1 parent b57bc01 commit 2f247de

File tree

67 files changed

+6163
-67
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

67 files changed

+6163
-67
lines changed

sdk/resources/azure-mgmt-resource/azure/mgmt/resource/deploymentscripts/_deployment_scripts_client.py

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ class DeploymentScriptsClient(MultiApiClientMixin, SDKClient):
4646
:type profile: azure.profiles.KnownProfiles
4747
"""
4848

49-
DEFAULT_API_VERSION = '2019-10-01-preview'
49+
DEFAULT_API_VERSION = '2020-10-01'
5050
_PROFILE_TAG = "azure.mgmt.resource.deploymentscripts.DeploymentScriptsClient"
5151
LATEST_PROFILE = ProfileDefinition({
5252
_PROFILE_TAG: {
@@ -72,22 +72,36 @@ def _models_dict(cls, api_version):
7272
def models(cls, api_version=DEFAULT_API_VERSION):
7373
"""Module depends on the API version:
7474
75+
* 2019-10-01-preview: :mod:`v2019_10_01_preview.models<azure.mgmt.resource.deploymentscripts.v2019_10_01_preview.models>`
7576
* 2019-10-01-preview: :mod:`v2019_10_preview.models<azure.mgmt.resource.deploymentscripts.v2019_10_preview.models>`
77+
* 2020-10-01: :mod:`v2020_10_01.models<azure.mgmt.resource.deploymentscripts.v2020_10_01.models>`
7678
"""
7779
if api_version == '2019-10-01-preview':
80+
from .v2019_10_01_preview import models
81+
return models
82+
elif api_version == '2019-10-01-preview':
7883
from .v2019_10_preview import models
7984
return models
85+
elif api_version == '2020-10-01':
86+
from .v2020_10_01 import models
87+
return models
8088
raise NotImplementedError("APIVersion {} is not available".format(api_version))
8189

8290
@property
8391
def deployment_scripts(self):
8492
"""Instance depends on the API version:
8593
94+
* 2019-10-01-preview: :class:`DeploymentScriptsOperations<azure.mgmt.resource.deploymentscripts.v2019_10_01_preview.operations.DeploymentScriptsOperations>`
8695
* 2019-10-01-preview: :class:`DeploymentScriptsOperations<azure.mgmt.resource.deploymentscripts.v2019_10_preview.operations.DeploymentScriptsOperations>`
96+
* 2020-10-01: :class:`DeploymentScriptsOperations<azure.mgmt.resource.deploymentscripts.v2020_10_01.operations.DeploymentScriptsOperations>`
8797
"""
8898
api_version = self._get_api_version('deployment_scripts')
8999
if api_version == '2019-10-01-preview':
100+
from .v2019_10_01_preview.operations import DeploymentScriptsOperations as OperationClass
101+
elif api_version == '2019-10-01-preview':
90102
from .v2019_10_preview.operations import DeploymentScriptsOperations as OperationClass
103+
elif api_version == '2020-10-01':
104+
from .v2020_10_01.operations import DeploymentScriptsOperations as OperationClass
91105
else:
92106
raise NotImplementedError("APIVersion {} is not available".format(api_version))
93107
return OperationClass(self._client, self.config, Serializer(self._models_dict(api_version)), Deserializer(self._models_dict(api_version)))

sdk/resources/azure-mgmt-resource/azure/mgmt/resource/deploymentscripts/models.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@
44
# Licensed under the MIT License. See License.txt in the project root for
55
# license information.
66
# --------------------------------------------------------------------------
7-
from .v2019_10_preview.models import *
7+
from .v2020_10_01.models import *
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# Copyright (c) Microsoft Corporation. All rights reserved.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
6+
#
7+
# Code generated by Microsoft (R) AutoRest Code Generator.
8+
# Changes may cause incorrect behavior and will be lost if the code is
9+
# regenerated.
10+
# --------------------------------------------------------------------------
11+
12+
from ._configuration import DeploymentScriptsClientConfiguration
13+
from ._deployment_scripts_client import DeploymentScriptsClient
14+
__all__ = ['DeploymentScriptsClient', 'DeploymentScriptsClientConfiguration']
15+
16+
from .version import VERSION
17+
18+
__version__ = VERSION
19+
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# Copyright (c) Microsoft Corporation. All rights reserved.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
6+
#
7+
# Code generated by Microsoft (R) AutoRest Code Generator.
8+
# Changes may cause incorrect behavior and will be lost if the code is
9+
# regenerated.
10+
# --------------------------------------------------------------------------
11+
from msrestazure import AzureConfiguration
12+
13+
from .version import VERSION
14+
15+
16+
class DeploymentScriptsClientConfiguration(AzureConfiguration):
17+
"""Configuration for DeploymentScriptsClient
18+
Note that all parameters used to create this instance are saved as instance
19+
attributes.
20+
21+
:param credentials: Credentials needed for the client to connect to Azure.
22+
:type credentials: :mod:`A msrestazure Credentials
23+
object<msrestazure.azure_active_directory>`
24+
:param subscription_id: Subscription Id which forms part of the URI for
25+
every service call.
26+
:type subscription_id: str
27+
:param str base_url: Service URL
28+
"""
29+
30+
def __init__(
31+
self, credentials, subscription_id, base_url=None):
32+
33+
if credentials is None:
34+
raise ValueError("Parameter 'credentials' must not be None.")
35+
if subscription_id is None:
36+
raise ValueError("Parameter 'subscription_id' must not be None.")
37+
if not base_url:
38+
base_url = 'https://management.azure.com'
39+
40+
super(DeploymentScriptsClientConfiguration, self).__init__(base_url)
41+
42+
# Starting Autorest.Python 4.0.64, make connection pool activated by default
43+
self.keep_alive = True
44+
45+
self.add_user_agent('azure-mgmt-resource/{}'.format(VERSION))
46+
self.add_user_agent('Azure-SDK-For-Python')
47+
48+
self.credentials = credentials
49+
self.subscription_id = subscription_id
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# Copyright (c) Microsoft Corporation. All rights reserved.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
6+
#
7+
# Code generated by Microsoft (R) AutoRest Code Generator.
8+
# Changes may cause incorrect behavior and will be lost if the code is
9+
# regenerated.
10+
# --------------------------------------------------------------------------
11+
12+
from msrest.service_client import SDKClient
13+
from msrest import Serializer, Deserializer
14+
15+
from ._configuration import DeploymentScriptsClientConfiguration
16+
from .operations import DeploymentScriptsOperations
17+
from . import models
18+
19+
20+
class DeploymentScriptsClient(SDKClient):
21+
"""The APIs listed in this specification can be used to manage Deployment Scripts resource through the Azure Resource Manager.
22+
23+
:ivar config: Configuration for client.
24+
:vartype config: DeploymentScriptsClientConfiguration
25+
26+
:ivar deployment_scripts: DeploymentScripts operations
27+
:vartype deployment_scripts: azure.mgmt.resource.deploymentscripts.v2019_10_01_preview.operations.DeploymentScriptsOperations
28+
29+
:param credentials: Credentials needed for the client to connect to Azure.
30+
:type credentials: :mod:`A msrestazure Credentials
31+
object<msrestazure.azure_active_directory>`
32+
:param subscription_id: Subscription Id which forms part of the URI for
33+
every service call.
34+
:type subscription_id: str
35+
:param str base_url: Service URL
36+
"""
37+
38+
def __init__(
39+
self, credentials, subscription_id, base_url=None):
40+
41+
self.config = DeploymentScriptsClientConfiguration(credentials, subscription_id, base_url)
42+
super(DeploymentScriptsClient, self).__init__(self.config.credentials, self.config)
43+
44+
client_models = {k: v for k, v in models.__dict__.items() if isinstance(v, type)}
45+
self.api_version = '2019-10-01-preview'
46+
self._serialize = Serializer(client_models)
47+
self._deserialize = Deserializer(client_models)
48+
49+
self.deployment_scripts = DeploymentScriptsOperations(
50+
self._client, self.config, self._serialize, self._deserialize)
Lines changed: 79 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,79 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# Copyright (c) Microsoft Corporation. All rights reserved.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
6+
#
7+
# Code generated by Microsoft (R) AutoRest Code Generator.
8+
# Changes may cause incorrect behavior and will be lost if the code is
9+
# regenerated.
10+
# --------------------------------------------------------------------------
11+
12+
try:
13+
from ._models_py3 import AzureCliScript
14+
from ._models_py3 import AzurePowerShellScript
15+
from ._models_py3 import AzureResourceBase
16+
from ._models_py3 import ContainerConfiguration
17+
from ._models_py3 import DeploymentScript
18+
from ._models_py3 import DeploymentScriptsError, DeploymentScriptsErrorException
19+
from ._models_py3 import DeploymentScriptUpdateParameter
20+
from ._models_py3 import EnvironmentVariable
21+
from ._models_py3 import ErrorAdditionalInfo
22+
from ._models_py3 import ErrorResponse
23+
from ._models_py3 import ManagedServiceIdentity
24+
from ._models_py3 import ScriptLog
25+
from ._models_py3 import ScriptLogsList
26+
from ._models_py3 import ScriptStatus
27+
from ._models_py3 import StorageAccountConfiguration
28+
from ._models_py3 import SystemData
29+
from ._models_py3 import UserAssignedIdentity
30+
except (SyntaxError, ImportError):
31+
from ._models import AzureCliScript
32+
from ._models import AzurePowerShellScript
33+
from ._models import AzureResourceBase
34+
from ._models import ContainerConfiguration
35+
from ._models import DeploymentScript
36+
from ._models import DeploymentScriptsError, DeploymentScriptsErrorException
37+
from ._models import DeploymentScriptUpdateParameter
38+
from ._models import EnvironmentVariable
39+
from ._models import ErrorAdditionalInfo
40+
from ._models import ErrorResponse
41+
from ._models import ManagedServiceIdentity
42+
from ._models import ScriptLog
43+
from ._models import ScriptLogsList
44+
from ._models import ScriptStatus
45+
from ._models import StorageAccountConfiguration
46+
from ._models import SystemData
47+
from ._models import UserAssignedIdentity
48+
from ._paged_models import DeploymentScriptPaged
49+
from ._deployment_scripts_client_enums import (
50+
ManagedServiceIdentityType,
51+
CreatedByType,
52+
CleanupOptions,
53+
ScriptProvisioningState,
54+
)
55+
56+
__all__ = [
57+
'AzureCliScript',
58+
'AzurePowerShellScript',
59+
'AzureResourceBase',
60+
'ContainerConfiguration',
61+
'DeploymentScript',
62+
'DeploymentScriptsError', 'DeploymentScriptsErrorException',
63+
'DeploymentScriptUpdateParameter',
64+
'EnvironmentVariable',
65+
'ErrorAdditionalInfo',
66+
'ErrorResponse',
67+
'ManagedServiceIdentity',
68+
'ScriptLog',
69+
'ScriptLogsList',
70+
'ScriptStatus',
71+
'StorageAccountConfiguration',
72+
'SystemData',
73+
'UserAssignedIdentity',
74+
'DeploymentScriptPaged',
75+
'ManagedServiceIdentityType',
76+
'CreatedByType',
77+
'CleanupOptions',
78+
'ScriptProvisioningState',
79+
]
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# Copyright (c) Microsoft Corporation. All rights reserved.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
6+
#
7+
# Code generated by Microsoft (R) AutoRest Code Generator.
8+
# Changes may cause incorrect behavior and will be lost if the code is
9+
# regenerated.
10+
# --------------------------------------------------------------------------
11+
12+
from enum import Enum
13+
14+
15+
class ManagedServiceIdentityType(str, Enum):
16+
17+
user_assigned = "UserAssigned"
18+
19+
20+
class CreatedByType(str, Enum):
21+
22+
user = "User"
23+
application = "Application"
24+
managed_identity = "ManagedIdentity"
25+
key = "Key"
26+
27+
28+
class CleanupOptions(str, Enum):
29+
30+
always = "Always"
31+
on_success = "OnSuccess"
32+
on_expiration = "OnExpiration"
33+
34+
35+
class ScriptProvisioningState(str, Enum):
36+
37+
creating = "Creating"
38+
provisioning_resources = "ProvisioningResources"
39+
running = "Running"
40+
succeeded = "Succeeded"
41+
failed = "Failed"
42+
canceled = "Canceled"

0 commit comments

Comments
 (0)