diff --git a/src/containerapp/azext_containerapp/_clients.py b/src/containerapp/azext_containerapp/_clients.py index f63403e98af..0b250ec51e8 100644 --- a/src/containerapp/azext_containerapp/_clients.py +++ b/src/containerapp/azext_containerapp/_clients.py @@ -783,3 +783,120 @@ def list(cls, cmd, resource_group_name, environment_name, formatter=lambda x: x) app_list.append(formatted) return app_list + + +class StorageClient(): + @classmethod + def create_or_update(cls, cmd, resource_group_name, env_name, name, storage_envelope, no_wait=False): + management_hostname = cmd.cli_ctx.cloud.endpoints.resource_manager + api_version = STABLE_API_VERSION + sub_id = get_subscription_id(cmd.cli_ctx) + url_fmt = "{}/subscriptions/{}/resourceGroups/{}/providers/Microsoft.App/managedEnvironments/{}/storages/{}?api-version={}" + request_url = url_fmt.format( + management_hostname.strip('/'), + sub_id, + resource_group_name, + env_name, + name, + api_version) + + r = send_raw_request(cmd.cli_ctx, "PUT", request_url, body=json.dumps(storage_envelope)) + + if no_wait: + return r.json() + elif r.status_code == 201: + url_fmt = "{}/subscriptions/{}/resourceGroups/{}/providers/Microsoft.App/managedEnvironments/{}/storages/{}?api-version={}" + request_url = url_fmt.format( + management_hostname.strip('/'), + sub_id, + resource_group_name, + env_name, + name, + api_version) + return poll(cmd, request_url, "waiting") + + return r.json() + + @classmethod + def delete(cls, cmd, resource_group_name, env_name, name, no_wait=False): + management_hostname = cmd.cli_ctx.cloud.endpoints.resource_manager + api_version = STABLE_API_VERSION + sub_id = get_subscription_id(cmd.cli_ctx) + url_fmt = "{}/subscriptions/{}/resourceGroups/{}/providers/Microsoft.App/managedEnvironments/{}/storages/{}?api-version={}" + request_url = url_fmt.format( + management_hostname.strip('/'), + sub_id, + resource_group_name, + env_name, + name, + api_version) + + r = send_raw_request(cmd.cli_ctx, "DELETE", request_url) + + if no_wait: + return # API doesn't return JSON (it returns no content) + elif r.status_code in [200, 201, 202, 204]: + url_fmt = "{}/subscriptions/{}/resourceGroups/{}/providers/Microsoft.App/managedEnvironments/{}/storages/{}?api-version={}" + request_url = url_fmt.format( + management_hostname.strip('/'), + sub_id, + resource_group_name, + env_name, + name, + api_version) + if r.status_code == 200: # 200 successful delete, 204 means storage not found + from azure.cli.core.azclierror import ResourceNotFoundError + try: + poll(cmd, request_url, "scheduledfordelete") + except ResourceNotFoundError: + pass + logger.warning('Containerapp environment storage successfully deleted') + return + + @classmethod + def show(cls, cmd, resource_group_name, env_name, name): + management_hostname = cmd.cli_ctx.cloud.endpoints.resource_manager + api_version = STABLE_API_VERSION + sub_id = get_subscription_id(cmd.cli_ctx) + url_fmt = "{}/subscriptions/{}/resourceGroups/{}/providers/Microsoft.App/managedEnvironments/{}/storages/{}?api-version={}" + request_url = url_fmt.format( + management_hostname.strip('/'), + sub_id, + resource_group_name, + env_name, + name, + api_version) + + r = send_raw_request(cmd.cli_ctx, "GET", request_url) + return r.json() + + @classmethod + def list(cls, cmd, resource_group_name, env_name, formatter=lambda x: x): + env_list = [] + + management_hostname = cmd.cli_ctx.cloud.endpoints.resource_manager + api_version = STABLE_API_VERSION + sub_id = get_subscription_id(cmd.cli_ctx) + url_fmt = "{}/subscriptions/{}/resourceGroups/{}/providers/Microsoft.App/managedEnvironments/{}/storages?api-version={}" + request_url = url_fmt.format( + management_hostname.strip('/'), + sub_id, + resource_group_name, + env_name, + api_version) + + r = send_raw_request(cmd.cli_ctx, "GET", request_url) + j = r.json() + for env in j["value"]: + formatted = formatter(env) + env_list.append(formatted) + + while j.get("nextLink") is not None: + request_url = j["nextLink"] + r = send_raw_request(cmd.cli_ctx, "GET", request_url) + j = r.json() + for env in j["value"]: + formatted = formatter(env) + env_list.append(formatted) + + return env_list diff --git a/src/containerapp/azext_containerapp/_help.py b/src/containerapp/azext_containerapp/_help.py index 573610efecf..d5db7171bdf 100644 --- a/src/containerapp/azext_containerapp/_help.py +++ b/src/containerapp/azext_containerapp/_help.py @@ -382,6 +382,48 @@ az containerapp env dapr-component remove -g MyResourceGroup --dapr-component-name MyDaprComponentName --name MyEnvironment """ +helps['containerapp env storage'] = """ + type: group + short-summary: Commands to manage storage for the Container Apps environment. +""" + +helps['containerapp env storage list'] = """ + type: command + short-summary: List the storages for an environment. + examples: + - name: List the storages for an environment. + text: | + az containerapp env storage list -g MyResourceGroup -n MyEnvironment +""" + +helps['containerapp env storage show'] = """ + type: command + short-summary: Show the details of a storage. + examples: + - name: Show the details of a storage. + text: | + az containerapp env storage show -g MyResourceGroup --storage-name MyStorageName -n MyEnvironment +""" + +helps['containerapp env storage set'] = """ + type: command + short-summary: Create or update a storage. + examples: + - name: Create a storage. + text: | + az containerapp env storage set -g MyResourceGroup -n MyEnv --storage-name MyStorageName --access-mode ReadOnly --azure-file-account-key MyAccountKey --azure-file-account-name MyAccountName --azure-file-share-name MyShareName +""" + +helps['containerapp env storage remove'] = """ + type: command + short-summary: Remove a storage from an environment. + examples: + - name: Remove a storage from a Container Apps environment. + text: | + az containerapp env storage remove -g MyResourceGroup --storage-name MyStorageName -n MyEnvironment +""" + + # Identity Commands helps['containerapp identity'] = """ type: group diff --git a/src/containerapp/azext_containerapp/_models.py b/src/containerapp/azext_containerapp/_models.py index 6a474f89267..02e5bcb916a 100644 --- a/src/containerapp/azext_containerapp/_models.py +++ b/src/containerapp/azext_containerapp/_models.py @@ -231,3 +231,10 @@ "tenantId": None, # str "subscriptionId": None # str } + +AzureFileProperties = { + "accountName": None, + "accountKey": None, + "accessMode": None, + "shareName": None +} diff --git a/src/containerapp/azext_containerapp/_params.py b/src/containerapp/azext_containerapp/_params.py index 9ddf30dcb37..94c7e0394cc 100644 --- a/src/containerapp/azext_containerapp/_params.py +++ b/src/containerapp/azext_containerapp/_params.py @@ -147,6 +147,14 @@ def load_arguments(self, _): with self.argument_context('containerapp env show') as c: c.argument('name', name_type, help='Name of the Container Apps Environment.') + with self.argument_context('containerapp env storage') as c: + c.argument('name', id_part=None) + c.argument('storage_name', help="Name of the storage.") + c.argument('access_mode', id_part=None, arg_type=get_enum_type(["ReadWrite", "ReadOnly"]), help="Access mode for the AzureFile storage.") + c.argument('azure_file_account_key', help="Key of the AzureFile storage account.") + c.argument('azure_file_share_name', help="Name of the share on the AzureFile storage.") + c.argument('azure_file_account_name', help="Name of the AzureFile storage account.") + with self.argument_context('containerapp identity') as c: c.argument('user_assigned', nargs='+', help="Space-separated user identities.") c.argument('system_assigned', help="Boolean indicating whether to assign system-assigned identity.") diff --git a/src/containerapp/azext_containerapp/commands.py b/src/containerapp/azext_containerapp/commands.py index d6c60a9c063..3ef540e70bf 100644 --- a/src/containerapp/azext_containerapp/commands.py +++ b/src/containerapp/azext_containerapp/commands.py @@ -73,6 +73,12 @@ def load_command_table(self, _): g.custom_command('set', 'create_or_update_dapr_component') g.custom_command('remove', 'remove_dapr_component') + with self.command_group('containerapp env storage') as g: + g.custom_show_command('show', 'show_storage') + g.custom_command('list', 'list_storage') + g.custom_command('set', 'create_or_update_storage', supports_no_wait=True, exception_handler=ex_handler_factory()) + g.custom_command('remove', 'remove_storage', supports_no_wait=True, confirmation=True, exception_handler=ex_handler_factory()) + with self.command_group('containerapp identity') as g: g.custom_command('assign', 'assign_managed_identity', supports_no_wait=True, exception_handler=ex_handler_factory()) g.custom_command('remove', 'remove_managed_identity', supports_no_wait=True, exception_handler=ex_handler_factory()) diff --git a/src/containerapp/azext_containerapp/custom.py b/src/containerapp/azext_containerapp/custom.py index c0c221564f4..f4fe046f9a3 100644 --- a/src/containerapp/azext_containerapp/custom.py +++ b/src/containerapp/azext_containerapp/custom.py @@ -25,7 +25,7 @@ from msrest.exceptions import DeserializationError from ._client_factory import handle_raw_exception -from ._clients import ManagedEnvironmentClient, ContainerAppClient, GitHubActionClient, DaprComponentClient +from ._clients import ManagedEnvironmentClient, ContainerAppClient, GitHubActionClient, DaprComponentClient, StorageClient from ._github_oauth import get_github_access_token from ._models import ( ManagedEnvironment as ManagedEnvironmentModel, @@ -45,7 +45,8 @@ RegistryInfo as RegistryInfoModel, AzureCredentials as AzureCredentialsModel, SourceControl as SourceControlModel, - ManagedServiceIdentity as ManagedServiceIdentityModel) + ManagedServiceIdentity as ManagedServiceIdentityModel, + AzureFileProperties as AzureFilePropertiesModel) from ._utils import (_validate_subscription_registered, _get_location_from_resource_group, _ensure_location_allowed, parse_secret_flags, store_as_secret_and_return_secret_ref, parse_env_var_flags, _generate_log_analytics_if_not_provided, _get_existing_secrets, _convert_object_from_snake_to_camel_case, @@ -2312,3 +2313,64 @@ def containerapp_up_logic(cmd, resource_group_name, name, managed_env, image, en return ContainerAppClient.create_or_update(cmd, resource_group_name, name, containerapp_def) except Exception as e: handle_raw_exception(e) + + +def show_storage(cmd, name, storage_name, resource_group_name): + _validate_subscription_registered(cmd, "Microsoft.App") + + try: + return StorageClient.show(cmd, resource_group_name, name, storage_name) + except CLIError as e: + handle_raw_exception(e) + + +def list_storage(cmd, name, resource_group_name): + _validate_subscription_registered(cmd, "Microsoft.App") + + try: + return StorageClient.list(cmd, resource_group_name, name) + except CLIError as e: + handle_raw_exception(e) + + +def create_or_update_storage(cmd, storage_name, resource_group_name, name, azure_file_account_name, azure_file_share_name, azure_file_account_key, access_mode, no_wait=False): # pylint: disable=redefined-builtin + _validate_subscription_registered(cmd, "Microsoft.App") + + if len(azure_file_share_name) < 3: + raise ValidationError("File share name must be longer than 2 characters.") + + if len(azure_file_account_name) < 3: + raise ValidationError("Account name must be longer than 2 characters.") + + r = None + + try: + r = StorageClient.show(cmd, resource_group_name, name, storage_name) + except: + pass + + if r: + logger.warning("Only AzureFile account keys can be updated. In order to change the AzureFile share name or account name, please delete this storage and create a new one.") + + storage_def = AzureFilePropertiesModel + storage_def["accountKey"] = azure_file_account_key + storage_def["accountName"] = azure_file_account_name + storage_def["shareName"] = azure_file_share_name + storage_def["accessMode"] = access_mode + storage_envelope = {} + storage_envelope["properties"] = {} + storage_envelope["properties"]["azureFile"] = storage_def + + try: + return StorageClient.create_or_update(cmd, resource_group_name, name, storage_name, storage_envelope, no_wait) + except CLIError as e: + handle_raw_exception(e) + + +def remove_storage(cmd, storage_name, name, resource_group_name, no_wait=False): + _validate_subscription_registered(cmd, "Microsoft.App") + + try: + return StorageClient.delete(cmd, resource_group_name, name, storage_name, no_wait) + except CLIError as e: + handle_raw_exception(e) diff --git a/src/containerapp/azext_containerapp/tests/latest/recordings/test_containerapp_env_storage.yaml b/src/containerapp/azext_containerapp/tests/latest/recordings/test_containerapp_env_storage.yaml index 7d37806955d..82f0829b2e4 100644 --- a/src/containerapp/azext_containerapp/tests/latest/recordings/test_containerapp_env_storage.yaml +++ b/src/containerapp/azext_containerapp/tests/latest/recordings/test_containerapp_env_storage.yaml @@ -18,16 +18,16 @@ interactions: uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/clitest.rg000001?api-version=2021-04-01 response: body: - string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001","name":"clitest.rg000001","type":"Microsoft.Resources/resourceGroups","location":"eastus2","tags":{"product":"azurecli","cause":"automation","date":"2022-05-05T22:42:59Z"},"properties":{"provisioningState":"Succeeded"}}' + string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001","name":"clitest.rg000001","type":"Microsoft.Resources/resourceGroups","location":"eastus","tags":{"product":"azurecli","cause":"automation","date":"2022-05-12T21:08:48Z"},"properties":{"provisioningState":"Succeeded"}}' headers: cache-control: - no-cache content-length: - - '311' + - '310' content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:43:00 GMT + - Thu, 12 May 2022 21:08:50 GMT expires: - '-1' pragma: @@ -42,7 +42,7 @@ interactions: code: 200 message: OK - request: - body: '{"location": "eastus2", "properties": {"sku": {"name": "PerGB2018"}, "retentionInDays": + body: '{"location": "eastus", "properties": {"sku": {"name": "PerGB2018"}, "retentionInDays": 30, "workspaceCapping": {}}}' headers: Accept: @@ -54,7 +54,7 @@ interactions: Connection: - keep-alive Content-Length: - - '116' + - '115' Content-Type: - application/json ParameterSetName: @@ -66,36 +66,33 @@ interactions: response: body: string: "{\r\n \"properties\": {\r\n \"source\": \"Azure\",\r\n \"customerId\": - \"6ec385ac-22fd-44e6-8f62-7700154dcb09\",\r\n \"provisioningState\": \"Creating\",\r\n + \"615eec8d-4247-4bd4-b807-e5c08d185b5d\",\r\n \"provisioningState\": \"Creating\",\r\n \ \"sku\": {\r\n \"name\": \"pergb2018\",\r\n \"lastSkuUpdate\": - \"Thu, 05 May 2022 22:43:04 GMT\"\r\n },\r\n \"retentionInDays\": 30,\r\n + \"Thu, 12 May 2022 21:08:53 GMT\"\r\n },\r\n \"retentionInDays\": 30,\r\n \ \"features\": {\r\n \"legacy\": 0,\r\n \"searchVersion\": 1,\r\n \ \"enableLogAccessUsingOnlyResourcePermissions\": true\r\n },\r\n \ \"workspaceCapping\": {\r\n \"dailyQuotaGb\": -1.0,\r\n \"quotaNextResetTime\": - \"Fri, 06 May 2022 11:00:00 GMT\",\r\n \"dataIngestionStatus\": \"RespectQuota\"\r\n + \"Fri, 13 May 2022 14:00:00 GMT\",\r\n \"dataIngestionStatus\": \"RespectQuota\"\r\n \ },\r\n \"publicNetworkAccessForIngestion\": \"Enabled\",\r\n \"publicNetworkAccessForQuery\": - \"Enabled\",\r\n \"createdDate\": \"Thu, 05 May 2022 22:43:04 GMT\",\r\n - \ \"modifiedDate\": \"Thu, 05 May 2022 22:43:04 GMT\"\r\n },\r\n \"id\": + \"Enabled\",\r\n \"createdDate\": \"Thu, 12 May 2022 21:08:53 GMT\",\r\n + \ \"modifiedDate\": \"Thu, 12 May 2022 21:08:53 GMT\"\r\n },\r\n \"id\": \"/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/clitest.rg000001/providers/microsoft.operationalinsights/workspaces/containerapp-env000005\",\r\n \ \"name\": \"containerapp-env000005\",\r\n \"type\": \"Microsoft.OperationalInsights/workspaces\",\r\n - \ \"location\": \"eastus2\"\r\n}" + \ \"location\": \"eastus\"\r\n}" headers: - access-control-allow-origin: - - '*' cache-control: - no-cache content-length: - - '1079' + - '1078' content-type: - application/json date: - - Thu, 05 May 2022 22:43:04 GMT + - Thu, 12 May 2022 21:08:52 GMT pragma: - no-cache - request-context: - - appId=cid-v1:e6336c63-aab2-45f0-996a-e5dbab2a1508 server: - Microsoft-IIS/10.0 + - Microsoft-IIS/10.0 strict-transport-security: - max-age=31536000; includeSubDomains x-content-type-options: @@ -128,42 +125,39 @@ interactions: response: body: string: "{\r\n \"properties\": {\r\n \"source\": \"Azure\",\r\n \"customerId\": - \"6ec385ac-22fd-44e6-8f62-7700154dcb09\",\r\n \"provisioningState\": \"Succeeded\",\r\n + \"615eec8d-4247-4bd4-b807-e5c08d185b5d\",\r\n \"provisioningState\": \"Succeeded\",\r\n \ \"sku\": {\r\n \"name\": \"pergb2018\",\r\n \"lastSkuUpdate\": - \"Thu, 05 May 2022 22:43:04 GMT\"\r\n },\r\n \"retentionInDays\": 30,\r\n + \"Thu, 12 May 2022 21:08:53 GMT\"\r\n },\r\n \"retentionInDays\": 30,\r\n \ \"features\": {\r\n \"legacy\": 0,\r\n \"searchVersion\": 1,\r\n \ \"enableLogAccessUsingOnlyResourcePermissions\": true\r\n },\r\n \ \"workspaceCapping\": {\r\n \"dailyQuotaGb\": -1.0,\r\n \"quotaNextResetTime\": - \"Fri, 06 May 2022 11:00:00 GMT\",\r\n \"dataIngestionStatus\": \"RespectQuota\"\r\n + \"Fri, 13 May 2022 14:00:00 GMT\",\r\n \"dataIngestionStatus\": \"RespectQuota\"\r\n \ },\r\n \"publicNetworkAccessForIngestion\": \"Enabled\",\r\n \"publicNetworkAccessForQuery\": - \"Enabled\",\r\n \"createdDate\": \"Thu, 05 May 2022 22:43:04 GMT\",\r\n - \ \"modifiedDate\": \"Thu, 05 May 2022 22:43:05 GMT\"\r\n },\r\n \"id\": + \"Enabled\",\r\n \"createdDate\": \"Thu, 12 May 2022 21:08:53 GMT\",\r\n + \ \"modifiedDate\": \"Thu, 12 May 2022 21:08:54 GMT\"\r\n },\r\n \"id\": \"/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/clitest.rg000001/providers/microsoft.operationalinsights/workspaces/containerapp-env000005\",\r\n \ \"name\": \"containerapp-env000005\",\r\n \"type\": \"Microsoft.OperationalInsights/workspaces\",\r\n - \ \"location\": \"eastus2\"\r\n}" + \ \"location\": \"eastus\"\r\n}" headers: - access-control-allow-origin: - - '*' cache-control: - no-cache content-length: - - '1080' + - '1079' content-type: - application/json date: - - Thu, 05 May 2022 22:43:34 GMT + - Thu, 12 May 2022 21:09:23 GMT pragma: - no-cache - request-context: - - appId=cid-v1:e6336c63-aab2-45f0-996a-e5dbab2a1508 server: - Microsoft-IIS/10.0 + - Microsoft-IIS/10.0 strict-transport-security: - max-age=31536000; includeSubDomains transfer-encoding: - chunked vary: - - Accept-Encoding,Accept-Encoding + - Accept-Encoding x-content-type-options: - nosniff x-powered-by: @@ -193,11 +187,9 @@ interactions: uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/clitest.rg000001/providers/Microsoft.OperationalInsights/workspaces/containerapp-env000005/sharedKeys?api-version=2020-08-01 response: body: - string: "{\r\n \"primarySharedKey\": \"TeD1lcoB5XcTTHDhrOYgTW30QhSH6nF5DSUGGuM3k2hVk/5TeNz6UYxD7AKyPmhlI+K4J9ZAgEzDPFdfvw3TSg==\",\r\n - \ \"secondarySharedKey\": \"A57L0WY68UsiXUnWhZKovVfeFOj0GCzBfCkqa5wRdZb/UEl1U0ppa7MjQcFERmi9DIqW+3Rf1OngkASOhlDVtA==\"\r\n}" + string: "{\r\n \"primarySharedKey\": \"HWhig3UmucPMqA0s21VaLJIsWOqcOZQxAdAMfgJ7La7vCjoablRZb1oqLyaaHjAeaulopHvFkN5XmAGYQowWjw==\",\r\n + \ \"secondarySharedKey\": \"T8EUHgQMrRGbANyfzaW64f+Mc4JD2rfKU77hMhFx3ZtIEXbpFqJ990z35K79FxBmX53Q5zTfyqyEYW0gcjCHwg==\"\r\n}" headers: - access-control-allow-origin: - - '*' cache-control: - no-cache cachecontrol: @@ -207,15 +199,14 @@ interactions: content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:43:36 GMT + - Thu, 12 May 2022 21:09:24 GMT expires: - '-1' pragma: - no-cache - request-context: - - appId=cid-v1:e6336c63-aab2-45f0-996a-e5dbab2a1508 server: - Microsoft-IIS/10.0 + - Microsoft-IIS/10.0 strict-transport-security: - max-age=31536000; includeSubDomains transfer-encoding: @@ -253,16 +244,16 @@ interactions: uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/clitest.rg000001?api-version=2021-04-01 response: body: - string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001","name":"clitest.rg000001","type":"Microsoft.Resources/resourceGroups","location":"eastus2","tags":{"product":"azurecli","cause":"automation","date":"2022-05-05T22:42:59Z"},"properties":{"provisioningState":"Succeeded"}}' + string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001","name":"clitest.rg000001","type":"Microsoft.Resources/resourceGroups","location":"eastus","tags":{"product":"azurecli","cause":"automation","date":"2022-05-12T21:08:48Z"},"properties":{"provisioningState":"Succeeded"}}' headers: cache-control: - no-cache content-length: - - '311' + - '310' content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:43:36 GMT + - Thu, 12 May 2022 21:09:24 GMT expires: - '-1' pragma: @@ -324,7 +315,7 @@ interactions: content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:43:37 GMT + - Thu, 12 May 2022 21:09:25 GMT expires: - '-1' pragma: @@ -386,7 +377,7 @@ interactions: content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:43:36 GMT + - Thu, 12 May 2022 21:09:24 GMT expires: - '-1' pragma: @@ -401,10 +392,10 @@ interactions: code: 200 message: OK - request: - body: '{"location": "eastus2", "tags": null, "properties": {"daprAIInstrumentationKey": + body: '{"location": "eastus", "tags": null, "properties": {"daprAIInstrumentationKey": null, "vnetConfiguration": null, "internalLoadBalancerEnabled": false, "appLogsConfiguration": {"destination": "log-analytics", "logAnalyticsConfiguration": {"customerId": - "6ec385ac-22fd-44e6-8f62-7700154dcb09", "sharedKey": "TeD1lcoB5XcTTHDhrOYgTW30QhSH6nF5DSUGGuM3k2hVk/5TeNz6UYxD7AKyPmhlI+K4J9ZAgEzDPFdfvw3TSg=="}}}}' + "615eec8d-4247-4bd4-b807-e5c08d185b5d", "sharedKey": "HWhig3UmucPMqA0s21VaLJIsWOqcOZQxAdAMfgJ7La7vCjoablRZb1oqLyaaHjAeaulopHvFkN5XmAGYQowWjw=="}}}}' headers: Accept: - '*/*' @@ -415,7 +406,7 @@ interactions: Connection: - keep-alive Content-Length: - - '400' + - '399' Content-Type: - application/json ParameterSetName: @@ -423,23 +414,23 @@ interactions: User-Agent: - python/3.8.6 (macOS-10.16-x86_64-i386-64bit) AZURECLI/2.36.0 method: PUT - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-01-01-preview + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-03-01 response: body: - string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus2","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-05T22:43:39.493595Z","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-05T22:43:39.493595Z"},"properties":{"provisioningState":"Waiting","defaultDomain":"happyplant-01456512.eastus2.azurecontainerapps.io","staticIp":"52.184.201.209","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"6ec385ac-22fd-44e6-8f62-7700154dcb09"}}}}' + string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-12T21:09:27.2242746Z","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-12T21:09:27.2242746Z"},"properties":{"provisioningState":"Waiting","defaultDomain":"blacksky-9a532b44.eastus.azurecontainerapps.io","staticIp":"20.102.22.100","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"615eec8d-4247-4bd4-b807-e5c08d185b5d"}},"zoneRedundant":false}}' headers: api-supported-versions: - 2022-01-01-preview, 2022-03-01 azure-asyncoperation: - - https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.App/locations/eastus2/managedEnvironmentOperationStatuses/13786957-43b3-4777-8e5e-895b1d74de3e?api-version=2022-01-01-preview&azureAsyncOperation=true + - https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.App/locations/eastus/managedEnvironmentOperationStatuses/bbef8678-0c3c-498f-808a-118d6bb51145?api-version=2022-03-01&azureAsyncOperation=true cache-control: - no-cache content-length: - - '773' + - '792' content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:43:40 GMT + - Thu, 12 May 2022 21:09:27 GMT expires: - '-1' pragma: @@ -452,8 +443,8 @@ interactions: - nosniff x-ms-async-operation-timeout: - PT15M - x-ms-ratelimit-remaining-subscription-writes: - - '1199' + x-ms-ratelimit-remaining-subscription-resource-requests: + - '99' x-powered-by: - ASP.NET status: @@ -475,21 +466,21 @@ interactions: User-Agent: - python/3.8.6 (macOS-10.16-x86_64-i386-64bit) AZURECLI/2.36.0 method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-01-01-preview + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-03-01 response: body: - string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus2","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-05T22:43:39.493595","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-05T22:43:39.493595"},"properties":{"provisioningState":"Waiting","defaultDomain":"happyplant-01456512.eastus2.azurecontainerapps.io","staticIp":"52.184.201.209","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"6ec385ac-22fd-44e6-8f62-7700154dcb09"}}}}' + string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-12T21:09:27.2242746","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-12T21:09:27.2242746"},"properties":{"provisioningState":"Waiting","defaultDomain":"blacksky-9a532b44.eastus.azurecontainerapps.io","staticIp":"20.102.22.100","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"615eec8d-4247-4bd4-b807-e5c08d185b5d"}},"zoneRedundant":false}}' headers: api-supported-versions: - 2022-01-01-preview, 2022-03-01 cache-control: - no-cache content-length: - - '771' + - '790' content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:43:40 GMT + - Thu, 12 May 2022 21:09:29 GMT expires: - '-1' pragma: @@ -525,21 +516,21 @@ interactions: User-Agent: - python/3.8.6 (macOS-10.16-x86_64-i386-64bit) AZURECLI/2.36.0 method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-01-01-preview + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-03-01 response: body: - string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus2","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-05T22:43:39.493595","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-05T22:43:39.493595"},"properties":{"provisioningState":"Waiting","defaultDomain":"happyplant-01456512.eastus2.azurecontainerapps.io","staticIp":"52.184.201.209","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"6ec385ac-22fd-44e6-8f62-7700154dcb09"}}}}' + string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-12T21:09:27.2242746","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-12T21:09:27.2242746"},"properties":{"provisioningState":"Waiting","defaultDomain":"blacksky-9a532b44.eastus.azurecontainerapps.io","staticIp":"20.102.22.100","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"615eec8d-4247-4bd4-b807-e5c08d185b5d"}},"zoneRedundant":false}}' headers: api-supported-versions: - 2022-01-01-preview, 2022-03-01 cache-control: - no-cache content-length: - - '771' + - '790' content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:43:44 GMT + - Thu, 12 May 2022 21:09:32 GMT expires: - '-1' pragma: @@ -575,21 +566,21 @@ interactions: User-Agent: - python/3.8.6 (macOS-10.16-x86_64-i386-64bit) AZURECLI/2.36.0 method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-01-01-preview + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-03-01 response: body: - string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus2","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-05T22:43:39.493595","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-05T22:43:39.493595"},"properties":{"provisioningState":"Waiting","defaultDomain":"happyplant-01456512.eastus2.azurecontainerapps.io","staticIp":"52.184.201.209","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"6ec385ac-22fd-44e6-8f62-7700154dcb09"}}}}' + string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-12T21:09:27.2242746","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-12T21:09:27.2242746"},"properties":{"provisioningState":"Waiting","defaultDomain":"blacksky-9a532b44.eastus.azurecontainerapps.io","staticIp":"20.102.22.100","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"615eec8d-4247-4bd4-b807-e5c08d185b5d"}},"zoneRedundant":false}}' headers: api-supported-versions: - 2022-01-01-preview, 2022-03-01 cache-control: - no-cache content-length: - - '771' + - '790' content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:43:46 GMT + - Thu, 12 May 2022 21:09:35 GMT expires: - '-1' pragma: @@ -625,21 +616,21 @@ interactions: User-Agent: - python/3.8.6 (macOS-10.16-x86_64-i386-64bit) AZURECLI/2.36.0 method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-01-01-preview + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-03-01 response: body: - string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus2","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-05T22:43:39.493595","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-05T22:43:39.493595"},"properties":{"provisioningState":"Waiting","defaultDomain":"happyplant-01456512.eastus2.azurecontainerapps.io","staticIp":"52.184.201.209","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"6ec385ac-22fd-44e6-8f62-7700154dcb09"}}}}' + string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-12T21:09:27.2242746","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-12T21:09:27.2242746"},"properties":{"provisioningState":"Waiting","defaultDomain":"blacksky-9a532b44.eastus.azurecontainerapps.io","staticIp":"20.102.22.100","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"615eec8d-4247-4bd4-b807-e5c08d185b5d"}},"zoneRedundant":false}}' headers: api-supported-versions: - 2022-01-01-preview, 2022-03-01 cache-control: - no-cache content-length: - - '771' + - '790' content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:43:50 GMT + - Thu, 12 May 2022 21:09:38 GMT expires: - '-1' pragma: @@ -675,21 +666,21 @@ interactions: User-Agent: - python/3.8.6 (macOS-10.16-x86_64-i386-64bit) AZURECLI/2.36.0 method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-01-01-preview + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-03-01 response: body: - string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus2","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-05T22:43:39.493595","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-05T22:43:39.493595"},"properties":{"provisioningState":"Waiting","defaultDomain":"happyplant-01456512.eastus2.azurecontainerapps.io","staticIp":"52.184.201.209","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"6ec385ac-22fd-44e6-8f62-7700154dcb09"}}}}' + string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-12T21:09:27.2242746","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-12T21:09:27.2242746"},"properties":{"provisioningState":"Waiting","defaultDomain":"blacksky-9a532b44.eastus.azurecontainerapps.io","staticIp":"20.102.22.100","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"615eec8d-4247-4bd4-b807-e5c08d185b5d"}},"zoneRedundant":false}}' headers: api-supported-versions: - 2022-01-01-preview, 2022-03-01 cache-control: - no-cache content-length: - - '771' + - '790' content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:43:54 GMT + - Thu, 12 May 2022 21:09:41 GMT expires: - '-1' pragma: @@ -725,21 +716,21 @@ interactions: User-Agent: - python/3.8.6 (macOS-10.16-x86_64-i386-64bit) AZURECLI/2.36.0 method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-01-01-preview + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-03-01 response: body: - string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus2","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-05T22:43:39.493595","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-05T22:43:39.493595"},"properties":{"provisioningState":"Waiting","defaultDomain":"happyplant-01456512.eastus2.azurecontainerapps.io","staticIp":"52.184.201.209","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"6ec385ac-22fd-44e6-8f62-7700154dcb09"}}}}' + string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-12T21:09:27.2242746","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-12T21:09:27.2242746"},"properties":{"provisioningState":"Waiting","defaultDomain":"blacksky-9a532b44.eastus.azurecontainerapps.io","staticIp":"20.102.22.100","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"615eec8d-4247-4bd4-b807-e5c08d185b5d"}},"zoneRedundant":false}}' headers: api-supported-versions: - 2022-01-01-preview, 2022-03-01 cache-control: - no-cache content-length: - - '771' + - '790' content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:43:58 GMT + - Thu, 12 May 2022 21:09:44 GMT expires: - '-1' pragma: @@ -775,21 +766,21 @@ interactions: User-Agent: - python/3.8.6 (macOS-10.16-x86_64-i386-64bit) AZURECLI/2.36.0 method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-01-01-preview + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-03-01 response: body: - string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus2","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-05T22:43:39.493595","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-05T22:43:39.493595"},"properties":{"provisioningState":"Waiting","defaultDomain":"happyplant-01456512.eastus2.azurecontainerapps.io","staticIp":"52.184.201.209","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"6ec385ac-22fd-44e6-8f62-7700154dcb09"}}}}' + string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-12T21:09:27.2242746","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-12T21:09:27.2242746"},"properties":{"provisioningState":"Waiting","defaultDomain":"blacksky-9a532b44.eastus.azurecontainerapps.io","staticIp":"20.102.22.100","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"615eec8d-4247-4bd4-b807-e5c08d185b5d"}},"zoneRedundant":false}}' headers: api-supported-versions: - 2022-01-01-preview, 2022-03-01 cache-control: - no-cache content-length: - - '771' + - '790' content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:44:00 GMT + - Thu, 12 May 2022 21:09:47 GMT expires: - '-1' pragma: @@ -825,21 +816,21 @@ interactions: User-Agent: - python/3.8.6 (macOS-10.16-x86_64-i386-64bit) AZURECLI/2.36.0 method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-01-01-preview + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-03-01 response: body: - string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus2","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-05T22:43:39.493595","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-05T22:43:39.493595"},"properties":{"provisioningState":"Waiting","defaultDomain":"happyplant-01456512.eastus2.azurecontainerapps.io","staticIp":"52.184.201.209","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"6ec385ac-22fd-44e6-8f62-7700154dcb09"}}}}' + string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-12T21:09:27.2242746","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-12T21:09:27.2242746"},"properties":{"provisioningState":"Waiting","defaultDomain":"blacksky-9a532b44.eastus.azurecontainerapps.io","staticIp":"20.102.22.100","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"615eec8d-4247-4bd4-b807-e5c08d185b5d"}},"zoneRedundant":false}}' headers: api-supported-versions: - 2022-01-01-preview, 2022-03-01 cache-control: - no-cache content-length: - - '771' + - '790' content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:44:04 GMT + - Thu, 12 May 2022 21:09:50 GMT expires: - '-1' pragma: @@ -875,21 +866,21 @@ interactions: User-Agent: - python/3.8.6 (macOS-10.16-x86_64-i386-64bit) AZURECLI/2.36.0 method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-01-01-preview + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-03-01 response: body: - string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus2","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-05T22:43:39.493595","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-05T22:43:39.493595"},"properties":{"provisioningState":"Waiting","defaultDomain":"happyplant-01456512.eastus2.azurecontainerapps.io","staticIp":"52.184.201.209","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"6ec385ac-22fd-44e6-8f62-7700154dcb09"}}}}' + string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-12T21:09:27.2242746","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-12T21:09:27.2242746"},"properties":{"provisioningState":"Waiting","defaultDomain":"blacksky-9a532b44.eastus.azurecontainerapps.io","staticIp":"20.102.22.100","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"615eec8d-4247-4bd4-b807-e5c08d185b5d"}},"zoneRedundant":false}}' headers: api-supported-versions: - 2022-01-01-preview, 2022-03-01 cache-control: - no-cache content-length: - - '771' + - '790' content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:44:07 GMT + - Thu, 12 May 2022 21:09:52 GMT expires: - '-1' pragma: @@ -925,21 +916,21 @@ interactions: User-Agent: - python/3.8.6 (macOS-10.16-x86_64-i386-64bit) AZURECLI/2.36.0 method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-01-01-preview + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-03-01 response: body: - string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus2","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-05T22:43:39.493595","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-05T22:43:39.493595"},"properties":{"provisioningState":"Waiting","defaultDomain":"happyplant-01456512.eastus2.azurecontainerapps.io","staticIp":"52.184.201.209","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"6ec385ac-22fd-44e6-8f62-7700154dcb09"}}}}' + string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-12T21:09:27.2242746","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-12T21:09:27.2242746"},"properties":{"provisioningState":"Waiting","defaultDomain":"blacksky-9a532b44.eastus.azurecontainerapps.io","staticIp":"20.102.22.100","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"615eec8d-4247-4bd4-b807-e5c08d185b5d"}},"zoneRedundant":false}}' headers: api-supported-versions: - 2022-01-01-preview, 2022-03-01 cache-control: - no-cache content-length: - - '771' + - '790' content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:44:09 GMT + - Thu, 12 May 2022 21:09:56 GMT expires: - '-1' pragma: @@ -975,21 +966,21 @@ interactions: User-Agent: - python/3.8.6 (macOS-10.16-x86_64-i386-64bit) AZURECLI/2.36.0 method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-01-01-preview + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-03-01 response: body: - string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus2","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-05T22:43:39.493595","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-05T22:43:39.493595"},"properties":{"provisioningState":"Waiting","defaultDomain":"happyplant-01456512.eastus2.azurecontainerapps.io","staticIp":"52.184.201.209","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"6ec385ac-22fd-44e6-8f62-7700154dcb09"}}}}' + string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-12T21:09:27.2242746","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-12T21:09:27.2242746"},"properties":{"provisioningState":"Waiting","defaultDomain":"blacksky-9a532b44.eastus.azurecontainerapps.io","staticIp":"20.102.22.100","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"615eec8d-4247-4bd4-b807-e5c08d185b5d"}},"zoneRedundant":false}}' headers: api-supported-versions: - 2022-01-01-preview, 2022-03-01 cache-control: - no-cache content-length: - - '771' + - '790' content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:44:12 GMT + - Thu, 12 May 2022 21:09:59 GMT expires: - '-1' pragma: @@ -1025,21 +1016,21 @@ interactions: User-Agent: - python/3.8.6 (macOS-10.16-x86_64-i386-64bit) AZURECLI/2.36.0 method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-01-01-preview + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-03-01 response: body: - string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus2","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-05T22:43:39.493595","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-05T22:43:39.493595"},"properties":{"provisioningState":"Waiting","defaultDomain":"happyplant-01456512.eastus2.azurecontainerapps.io","staticIp":"52.184.201.209","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"6ec385ac-22fd-44e6-8f62-7700154dcb09"}}}}' + string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-12T21:09:27.2242746","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-12T21:09:27.2242746"},"properties":{"provisioningState":"Waiting","defaultDomain":"blacksky-9a532b44.eastus.azurecontainerapps.io","staticIp":"20.102.22.100","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"615eec8d-4247-4bd4-b807-e5c08d185b5d"}},"zoneRedundant":false}}' headers: api-supported-versions: - 2022-01-01-preview, 2022-03-01 cache-control: - no-cache content-length: - - '771' + - '790' content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:44:15 GMT + - Thu, 12 May 2022 21:10:02 GMT expires: - '-1' pragma: @@ -1075,21 +1066,21 @@ interactions: User-Agent: - python/3.8.6 (macOS-10.16-x86_64-i386-64bit) AZURECLI/2.36.0 method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-01-01-preview + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-03-01 response: body: - string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus2","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-05T22:43:39.493595","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-05T22:43:39.493595"},"properties":{"provisioningState":"Succeeded","defaultDomain":"happyplant-01456512.eastus2.azurecontainerapps.io","staticIp":"52.184.201.209","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"6ec385ac-22fd-44e6-8f62-7700154dcb09"}}}}' + string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-12T21:09:27.2242746","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-12T21:09:27.2242746"},"properties":{"provisioningState":"Succeeded","defaultDomain":"blacksky-9a532b44.eastus.azurecontainerapps.io","staticIp":"20.102.22.100","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"615eec8d-4247-4bd4-b807-e5c08d185b5d"}},"zoneRedundant":false}}' headers: api-supported-versions: - 2022-01-01-preview, 2022-03-01 cache-control: - no-cache content-length: - - '773' + - '792' content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:44:18 GMT + - Thu, 12 May 2022 21:10:05 GMT expires: - '-1' pragma: @@ -1157,7 +1148,7 @@ interactions: content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:44:18 GMT + - Thu, 12 May 2022 21:10:06 GMT expires: - '-1' pragma: @@ -1187,21 +1178,21 @@ interactions: User-Agent: - python/3.8.6 (macOS-10.16-x86_64-i386-64bit) AZURECLI/2.36.0 method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-01-01-preview + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002?api-version=2022-03-01 response: body: - string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus2","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-05T22:43:39.493595","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-05T22:43:39.493595"},"properties":{"provisioningState":"Succeeded","defaultDomain":"happyplant-01456512.eastus2.azurecontainerapps.io","staticIp":"52.184.201.209","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"6ec385ac-22fd-44e6-8f62-7700154dcb09"}}}}' + string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002","name":"containerapp-env000002","type":"Microsoft.App/managedEnvironments","location":"eastus","systemData":{"createdBy":"silasstrawn@microsoft.com","createdByType":"User","createdAt":"2022-05-12T21:09:27.2242746","lastModifiedBy":"silasstrawn@microsoft.com","lastModifiedByType":"User","lastModifiedAt":"2022-05-12T21:09:27.2242746"},"properties":{"provisioningState":"Succeeded","defaultDomain":"blacksky-9a532b44.eastus.azurecontainerapps.io","staticIp":"20.102.22.100","appLogsConfiguration":{"destination":"log-analytics","logAnalyticsConfiguration":{"customerId":"615eec8d-4247-4bd4-b807-e5c08d185b5d"}},"zoneRedundant":false}}' headers: api-supported-versions: - 2022-01-01-preview, 2022-03-01 cache-control: - no-cache content-length: - - '773' + - '792' content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:44:20 GMT + - Thu, 12 May 2022 21:10:06 GMT expires: - '-1' pragma: @@ -1240,16 +1231,16 @@ interactions: uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/clitest.rg000001?api-version=2021-04-01 response: body: - string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001","name":"clitest.rg000001","type":"Microsoft.Resources/resourceGroups","location":"eastus2","tags":{"product":"azurecli","cause":"automation","date":"2022-05-05T22:42:59Z"},"properties":{"provisioningState":"Succeeded"}}' + string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001","name":"clitest.rg000001","type":"Microsoft.Resources/resourceGroups","location":"eastus","tags":{"product":"azurecli","cause":"automation","date":"2022-05-12T21:08:48Z"},"properties":{"provisioningState":"Succeeded"}}' headers: cache-control: - no-cache content-length: - - '311' + - '310' content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:44:25 GMT + - Thu, 12 May 2022 21:10:11 GMT expires: - '-1' pragma: @@ -1264,7 +1255,7 @@ interactions: code: 200 message: OK - request: - body: '{"sku": {"name": "Standard_ZRS"}, "kind": "StorageV2", "location": "eastus2", + body: '{"sku": {"name": "Standard_ZRS"}, "kind": "StorageV2", "location": "eastus", "properties": {"encryption": {"services": {"blob": {}}, "keySource": "Microsoft.Storage"}, "largeFileSharesState": "Enabled"}}' headers: @@ -1277,7 +1268,7 @@ interactions: Connection: - keep-alive Content-Length: - - '204' + - '203' Content-Type: - application/json ParameterSetName: @@ -1297,11 +1288,11 @@ interactions: content-type: - text/plain; charset=utf-8 date: - - Thu, 05 May 2022 22:44:29 GMT + - Thu, 12 May 2022 21:10:15 GMT expires: - '-1' location: - - https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Storage/locations/eastus2/asyncoperations/e3d86a1f-ee3a-44a0-a115-18c5b365d2f8?monitor=true&api-version=2021-09-01 + - https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Storage/locations/eastus/asyncoperations/4bcab18a-4d14-4de6-85c2-330226291aab?monitor=true&api-version=2021-09-01 pragma: - no-cache server: @@ -1331,19 +1322,19 @@ interactions: User-Agent: - AZURECLI/2.36.0 azsdk-python-azure-mgmt-storage/20.0.0 Python/3.8.6 (macOS-10.16-x86_64-i386-64bit) method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Storage/locations/eastus2/asyncoperations/e3d86a1f-ee3a-44a0-a115-18c5b365d2f8?monitor=true&api-version=2021-09-01 + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Storage/locations/eastus/asyncoperations/4bcab18a-4d14-4de6-85c2-330226291aab?monitor=true&api-version=2021-09-01 response: body: - string: '{"sku":{"name":"Standard_ZRS","tier":"Standard"},"kind":"StorageV2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.Storage/storageAccounts/storage000003","name":"storage000003","type":"Microsoft.Storage/storageAccounts","location":"eastus2","tags":{},"properties":{"keyCreationTime":{"key1":"2022-05-05T22:44:28.2060948Z","key2":"2022-05-05T22:44:28.2060948Z"},"privateEndpointConnections":[],"minimumTlsVersion":"TLS1_0","allowBlobPublicAccess":true,"largeFileSharesState":"Enabled","networkAcls":{"bypass":"AzureServices","virtualNetworkRules":[],"ipRules":[],"defaultAction":"Allow"},"supportsHttpsTrafficOnly":true,"encryption":{"services":{"file":{"keyType":"Account","enabled":true,"lastEnabledTime":"2022-05-05T22:44:28.2060948Z"},"blob":{"keyType":"Account","enabled":true,"lastEnabledTime":"2022-05-05T22:44:28.2060948Z"}},"keySource":"Microsoft.Storage"},"accessTier":"Hot","provisioningState":"Succeeded","creationTime":"2022-05-05T22:44:28.0029628Z","primaryEndpoints":{"dfs":"https://storage000003.dfs.core.windows.net/","web":"https://storage000003.z20.web.core.windows.net/","blob":"https://storage000003.blob.core.windows.net/","queue":"https://storage000003.queue.core.windows.net/","table":"https://storage000003.table.core.windows.net/","file":"https://storage000003.file.core.windows.net/"},"primaryLocation":"eastus2","statusOfPrimary":"available"}}' + string: '{"sku":{"name":"Standard_ZRS","tier":"Standard"},"kind":"StorageV2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.Storage/storageAccounts/storage000003","name":"storage000003","type":"Microsoft.Storage/storageAccounts","location":"eastus","tags":{},"properties":{"keyCreationTime":{"key1":"2022-05-12T21:10:14.3024548Z","key2":"2022-05-12T21:10:14.3024548Z"},"privateEndpointConnections":[],"minimumTlsVersion":"TLS1_0","allowBlobPublicAccess":true,"largeFileSharesState":"Enabled","networkAcls":{"bypass":"AzureServices","virtualNetworkRules":[],"ipRules":[],"defaultAction":"Allow"},"supportsHttpsTrafficOnly":true,"encryption":{"services":{"file":{"keyType":"Account","enabled":true,"lastEnabledTime":"2022-05-12T21:10:14.3180588Z"},"blob":{"keyType":"Account","enabled":true,"lastEnabledTime":"2022-05-12T21:10:14.3180588Z"}},"keySource":"Microsoft.Storage"},"accessTier":"Hot","provisioningState":"Succeeded","creationTime":"2022-05-12T21:10:14.1774115Z","primaryEndpoints":{"dfs":"https://storage000003.dfs.core.windows.net/","web":"https://storage000003.z13.web.core.windows.net/","blob":"https://storage000003.blob.core.windows.net/","queue":"https://storage000003.queue.core.windows.net/","table":"https://storage000003.table.core.windows.net/","file":"https://storage000003.file.core.windows.net/"},"primaryLocation":"eastus","statusOfPrimary":"available"}}' headers: cache-control: - no-cache content-length: - - '1433' + - '1431' content-type: - application/json date: - - Thu, 05 May 2022 22:44:46 GMT + - Thu, 12 May 2022 21:10:32 GMT expires: - '-1' pragma: @@ -1393,9 +1384,9 @@ interactions: content-type: - application/json date: - - Thu, 05 May 2022 22:44:47 GMT + - Thu, 12 May 2022 21:10:33 GMT etag: - - '"0x8DA2EE8DBED0654"' + - '"0x8DA345BDAB1A5E0"' expires: - '-1' pragma: @@ -1432,7 +1423,7 @@ interactions: uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.Storage/storageAccounts/storage000003/listKeys?api-version=2021-09-01&$expand=kerb response: body: - string: '{"keys":[{"creationTime":"2022-05-05T22:44:28.2060948Z","keyName":"key1","value":"veryFakedStorageAccountKey==","permissions":"FULL"},{"creationTime":"2022-05-05T22:44:28.2060948Z","keyName":"key2","value":"veryFakedStorageAccountKey==","permissions":"FULL"}]}' + string: '{"keys":[{"creationTime":"2022-05-12T21:10:14.3024548Z","keyName":"key1","value":"veryFakedStorageAccountKey==","permissions":"FULL"},{"creationTime":"2022-05-12T21:10:14.3024548Z","keyName":"key2","value":"veryFakedStorageAccountKey==","permissions":"FULL"}]}' headers: cache-control: - no-cache @@ -1441,7 +1432,7 @@ interactions: content-type: - application/json date: - - Thu, 05 May 2022 22:44:48 GMT + - Thu, 12 May 2022 21:10:35 GMT expires: - '-1' pragma: @@ -1510,7 +1501,7 @@ interactions: content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:44:49 GMT + - Thu, 12 May 2022 21:10:35 GMT expires: - '-1' pragma: @@ -1544,7 +1535,7 @@ interactions: uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002/storages/storage000003?api-version=2022-03-01 response: body: - string: '{"code":"KubeEnvironmentStorageNotFound","message":"Storage storage000003 + string: '{"code":"ManagedEnvironmentStorageNotFound","message":"Storage storage000003 not found under managed environment"}' headers: api-supported-versions: @@ -1552,11 +1543,11 @@ interactions: cache-control: - no-cache content-length: - - '111' + - '114' content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:44:49 GMT + - Thu, 12 May 2022 21:10:36 GMT expires: - '-1' pragma: @@ -1608,7 +1599,7 @@ interactions: content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:44:51 GMT + - Thu, 12 May 2022 21:10:38 GMT expires: - '-1' pragma: @@ -1678,7 +1669,7 @@ interactions: content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:44:51 GMT + - Thu, 12 May 2022 21:10:38 GMT expires: - '-1' pragma: @@ -1722,7 +1713,7 @@ interactions: content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:44:52 GMT + - Thu, 12 May 2022 21:10:39 GMT expires: - '-1' pragma: @@ -1790,7 +1781,7 @@ interactions: content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:44:53 GMT + - Thu, 12 May 2022 21:10:39 GMT expires: - '-1' pragma: @@ -1834,7 +1825,7 @@ interactions: content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:44:54 GMT + - Thu, 12 May 2022 21:10:39 GMT expires: - '-1' pragma: @@ -1902,7 +1893,7 @@ interactions: content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:44:53 GMT + - Thu, 12 May 2022 21:10:40 GMT expires: - '-1' pragma: @@ -1946,7 +1937,7 @@ interactions: content-length: - '0' date: - - Thu, 05 May 2022 22:44:54 GMT + - Thu, 12 May 2022 21:10:42 GMT expires: - '-1' pragma: @@ -1983,7 +1974,7 @@ interactions: uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest.rg000001/providers/Microsoft.App/managedEnvironments/containerapp-env000002/storages/storage000003?api-version=2022-03-01 response: body: - string: '{"code":"KubeEnvironmentStorageNotFound","message":"Storage storage000003 + string: '{"code":"ManagedEnvironmentStorageNotFound","message":"Storage storage000003 not found under managed environment"}' headers: api-supported-versions: @@ -1991,11 +1982,11 @@ interactions: cache-control: - no-cache content-length: - - '111' + - '114' content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:44:55 GMT + - Thu, 12 May 2022 21:10:43 GMT expires: - '-1' pragma: @@ -2059,7 +2050,7 @@ interactions: content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:44:56 GMT + - Thu, 12 May 2022 21:10:44 GMT expires: - '-1' pragma: @@ -2103,7 +2094,7 @@ interactions: content-type: - application/json; charset=utf-8 date: - - Thu, 05 May 2022 22:44:57 GMT + - Thu, 12 May 2022 21:10:45 GMT expires: - '-1' pragma: diff --git a/src/containerapp/azext_containerapp/tests/latest/test_containerapp_commands.py b/src/containerapp/azext_containerapp/tests/latest/test_containerapp_commands.py index fa9b2b12e6c..1316c8e80b7 100644 --- a/src/containerapp/azext_containerapp/tests/latest/test_containerapp_commands.py +++ b/src/containerapp/azext_containerapp/tests/latest/test_containerapp_commands.py @@ -7,7 +7,7 @@ import time import unittest -from azure.cli.testsdk.scenario_tests import AllowLargeResponse +from azure.cli.testsdk.scenario_tests import AllowLargeResponse, live_only from azure.cli.testsdk import (ScenarioTest, ResourceGroupPreparer, JMESPathCheck) @@ -310,4 +310,48 @@ def test_containerapp_dapr_e2e(self, resource_group): JMESPathCheck('properties.configuration.dapr.appPort', 80), JMESPathCheck('properties.configuration.dapr.appProtocol', "http"), JMESPathCheck('properties.configuration.dapr.enabled', False), - ]) \ No newline at end of file + ]) + + +class ContainerappEnvStorageTests(ScenarioTest): + @AllowLargeResponse(8192) + @ResourceGroupPreparer(location="eastus") + def test_containerapp_env_storage(self, resource_group): + env_name = self.create_random_name(prefix='containerapp-env', length=24) + storage_name = self.create_random_name(prefix='storage', length=24) + shares_name = self.create_random_name(prefix='share', length=24) + logs_workspace_name = self.create_random_name(prefix='containerapp-env', length=24) + + logs_workspace_id = self.cmd('monitor log-analytics workspace create -g {} -n {}'.format(resource_group, logs_workspace_name)).get_output_in_json()["customerId"] + logs_workspace_key = self.cmd('monitor log-analytics workspace get-shared-keys -g {} -n {}'.format(resource_group, logs_workspace_name)).get_output_in_json()["primarySharedKey"] + + self.cmd('containerapp env create -g {} -n {} --logs-workspace-id {} --logs-workspace-key {}'.format(resource_group, env_name, logs_workspace_id, logs_workspace_key)) + + containerapp_env = self.cmd('containerapp env show -g {} -n {}'.format(resource_group, env_name)).get_output_in_json() + + while containerapp_env["properties"]["provisioningState"].lower() == "waiting": + time.sleep(5) + containerapp_env = self.cmd('containerapp env show -g {} -n {}'.format(resource_group, env_name)).get_output_in_json() + + self.cmd('storage account create -g {} -n {} --kind StorageV2 --sku Standard_ZRS --enable-large-file-share'.format(resource_group, storage_name)) + self.cmd('storage share-rm create -g {} -n {} --storage-account {} --access-tier "TransactionOptimized" --quota 1024'.format(resource_group, shares_name, storage_name)) + + storage_keys = self.cmd('az storage account keys list -g {} -n {}'.format(resource_group, storage_name)).get_output_in_json()[0] + + self.cmd('containerapp env storage set -g {} -n {} --storage-name {} --azure-file-account-name {} --azure-file-account-key {} --access-mode ReadOnly --azure-file-share-name {}'.format(resource_group, env_name, storage_name, storage_name, storage_keys["value"], shares_name), checks=[ + JMESPathCheck('name', storage_name), + ]) + + self.cmd('containerapp env storage show -g {} -n {} --storage-name {}'.format(resource_group, env_name, storage_name), checks=[ + JMESPathCheck('name', storage_name), + ]) + + self.cmd('containerapp env storage list -g {} -n {}'.format(resource_group, env_name), checks=[ + JMESPathCheck('[0].name', storage_name), + ]) + + self.cmd('containerapp env storage remove -g {} -n {} --storage-name {} --yes'.format(resource_group, env_name, storage_name)) + + self.cmd('containerapp env storage list -g {} -n {}'.format(resource_group, env_name), checks=[ + JMESPathCheck('length(@)', 0), + ])