diff --git a/src/azure-cli/azure/cli/command_modules/acs/_help.py b/src/azure-cli/azure/cli/command_modules/acs/_help.py index 76b675c4029..c99ac3e9c41 100644 --- a/src/azure-cli/azure/cli/command_modules/acs/_help.py +++ b/src/azure-cli/azure/cli/command_modules/acs/_help.py @@ -1173,6 +1173,36 @@ short-summary: Comma-separated key-value pairs to specify custom headers. """ +helps['aks nodepool stop'] = """ + type: command + short-summary: Stop running agent pool in the managed Kubernetes cluster. + parameters: + - name: --nodepool-name + type: string + short-summary: Agent pool name + - name: --aks-custom-headers + type: string + short-summary: Send custom headers. When specified, format should be Key1=Value1,Key2=Value2 + examples: + - name: Stop agent pool in the managed cluster + text: az aks nodepool stop --nodepool-name nodepool1 -g MyResourceGroup --cluster-name MyManagedCluster +""" + +helps['aks nodepool start'] = """ + type: command + short-summary: Start stopped agent pool in the managed Kubernetes cluster. + parameters: + - name: --nodepool-name + type: string + short-summary: Agent pool name + - name: --aks-custom-headers + type: string + short-summary: Send custom headers. When specified, format should be Key1=Value1,Key2=Value2 + examples: + - name: Start agent pool in the managed cluster + text: az aks nodepool start --nodepool-name nodepool1 -g MyResourceGroup --cluster-name MyManagedCluster +""" + helps['aks remove-dev-spaces'] = """ type: command short-summary: Remove Azure Dev Spaces from a managed Kubernetes cluster. diff --git a/src/azure-cli/azure/cli/command_modules/acs/commands.py b/src/azure-cli/azure/cli/command_modules/acs/commands.py index a17da0f0580..487bf2494bf 100644 --- a/src/azure-cli/azure/cli/command_modules/acs/commands.py +++ b/src/azure-cli/azure/cli/command_modules/acs/commands.py @@ -132,6 +132,8 @@ def load_command_table(self, _): g.custom_command('delete', 'aks_agentpool_delete', supports_no_wait=True) g.custom_show_command('show', 'aks_agentpool_show', table_transformer=aks_agentpool_show_table_format) g.custom_command('list', 'aks_agentpool_list', table_transformer=aks_agentpool_list_table_format) + g.custom_command('stop', 'aks_agentpool_stop', supports_no_wait=True) + g.custom_command('start', 'aks_agentpool_start', supports_no_wait=True) g.wait_command('wait') with self.command_group('aks command', managed_clusters_sdk, client_factory=cf_managed_clusters) as g: diff --git a/src/azure-cli/azure/cli/command_modules/acs/custom.py b/src/azure-cli/azure/cli/command_modules/acs/custom.py index cbded5ae074..fa3bd1f44a2 100644 --- a/src/azure-cli/azure/cli/command_modules/acs/custom.py +++ b/src/azure-cli/azure/cli/command_modules/acs/custom.py @@ -3136,6 +3136,52 @@ def aks_agentpool_scale(cmd, client, resource_group_name, cluster_name, ) +def aks_agentpool_start(cmd, # pylint: disable=unused-argument + client, + resource_group_name, + cluster_name, + nodepool_name, + aks_custom_headers=None, + no_wait=False): + agentpool_exists = False + instances = client.list(resource_group_name, cluster_name) + for agentpool_profile in instances: + if agentpool_profile.name.lower() == nodepool_name.lower(): + agentpool_exists = True + break + if not agentpool_exists: + raise InvalidArgumentValueError( + "Node pool {} doesnt exist, use 'aks nodepool list' to get current node pool list".format(nodepool_name)) + instance = client.get(resource_group_name, cluster_name, nodepool_name) + PowerState = cmd.get_models('PowerState', operation_group='agent_pools') + power_state = PowerState(code="Running") + instance.power_state = power_state + return sdk_no_wait(no_wait, client.begin_create_or_update, resource_group_name, cluster_name, nodepool_name, instance, headers=None) + + +def aks_agentpool_stop(cmd, # pylint: disable=unused-argument + client, + resource_group_name, + cluster_name, + nodepool_name, + aks_custom_headers=None, + no_wait=False): + agentpool_exists = False + instances = client.list(resource_group_name, cluster_name) + for agentpool_profile in instances: + if agentpool_profile.name.lower() == nodepool_name.lower(): + agentpool_exists = True + break + if not agentpool_exists: + raise InvalidArgumentValueError( + "Node pool {} doesnt exist, use 'aks nodepool list' to get current node pool list".format(nodepool_name)) + instance = client.get(resource_group_name, cluster_name, nodepool_name) + PowerState = cmd.get_models('PowerState', operation_group='agent_pools') + power_state = PowerState(code="Stopped") + instance.power_state = power_state + return sdk_no_wait(no_wait, client.begin_create_or_update, resource_group_name, cluster_name, nodepool_name, instance, headers=None) + + def aks_agentpool_delete(cmd, client, resource_group_name, cluster_name, nodepool_name, no_wait=False): diff --git a/src/azure-cli/azure/cli/command_modules/acs/tests/latest/recordings/test_aks_nodepool_stop_and_start.yaml b/src/azure-cli/azure/cli/command_modules/acs/tests/latest/recordings/test_aks_nodepool_stop_and_start.yaml new file mode 100644 index 00000000000..969ae30f775 --- /dev/null +++ b/src/azure-cli/azure/cli/command_modules/acs/tests/latest/recordings/test_aks_nodepool_stop_and_start.yaml @@ -0,0 +1,1931 @@ +interactions: +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + CommandName: + - aks create + Connection: + - keep-alive + ParameterSetName: + - --resource-group --name --ssh-key-value + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-resource/21.1.0b1 Python/3.7.9 (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/clitest000001?api-version=2021-04-01 + response: + body: + string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest000001","name":"clitest000001","type":"Microsoft.Resources/resourceGroups","location":"westcentralus","tags":{"product":"azurecli","cause":"automation","date":"2022-06-28T19:07:07Z"},"properties":{"provisioningState":"Succeeded"}}' + headers: + cache-control: + - no-cache + content-length: + - '311' + content-type: + - application/json; charset=utf-8 + date: + - Tue, 28 Jun 2022 19:07:11 GMT + expires: + - '-1' + pragma: + - no-cache + strict-transport-security: + - max-age=31536000; includeSubDomains + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: '{"location": "westcentralus", "identity": {"type": "SystemAssigned"}, "properties": + {"kubernetesVersion": "", "dnsPrefix": "cliakstest-clitestl4ulryhrp-8ecadf", + "agentPoolProfiles": [{"count": 3, "vmSize": "Standard_DS2_v2", "workloadRuntime": + "OCIContainer", "osType": "Linux", "type": "VirtualMachineScaleSets", "mode": + "System", "enableNodePublicIP": false, "scaleSetPriority": "Regular", "scaleSetEvictionPolicy": + "Delete", "spotMaxPrice": -1.0, "enableEncryptionAtHost": false, "enableUltraSSD": + false, "enableFIPS": false, "name": "nodepool1"}], "linuxProfile": {"adminUsername": + "azureuser", "ssh": {"publicKeys": [{"keyData": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQCbIg1guRHbI0lV11wWDt1r2cUdcNd27CJsg+SfgC7miZeubtwUhbsPdhMQsfDyhOWHq1+ZL0M+nJZV63d/1dhmhtgyOqejUwrPlzKhydsbrsdUor+JmNJDdW01v7BXHyuymT8G4s09jCasNOwiufbP/qp72ruu0bIA1nySsvlf9pCQAuFkAnVnf/rFhUlOkhtRpwcq8SUNY2zRHR/EKb/4NWY1JzR4sa3q2fWIJdrrX0DvLoa5g9bIEd4Df79ba7v+yiUBOS0zT2ll+z4g9izHK3EO5d8hL4jYxcjKs+wcslSYRWrascfscLgMlMGh0CdKeNTDjHpGPncaf3Z+FwwwjWeuiNBxv7bJo13/8B/098KlVDl4GZqsoBCEjPyJfV6hO0y/LkRGkk7oHWKgeWAfKtfLItRp00eZ4fcJNK9kCaSMmEugoZWcI7NGbZXzqFWqbpRI7NcDP9+WIQ+i9U5vqWsqd/zng4kbuAJ6UuKqIzB0upYrLShfQE3SAck8oaLhJqqq56VfDuASNpJKidV+zq27HfSBmbXnkR/5AK337dc3MXKJypoK/QPMLKUAP5XLPbs+NddJQV7EZXd29DLgp+fRIg3edpKdO7ZErWhv7d+3Kws+e1Y+ypmR2WIVSwVyBEUfgv2C8Ts9gnTF4pNcEY/S2aBicz5Ew2+jdyGNQQ== + test@example.com\n"}]}}, "addonProfiles": {}, "enableRBAC": true, "enablePodSecurityPolicy": + false, "networkProfile": {"networkPlugin": "kubenet", "podCidr": "10.244.0.0/16", + "serviceCidr": "10.0.0.0/16", "dnsServiceIP": "10.0.0.10", "dockerBridgeCidr": + "172.17.0.1/16", "outboundType": "loadBalancer", "loadBalancerSku": "standard"}, + "disableLocalAccounts": false}}' + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + CommandName: + - aks create + Connection: + - keep-alive + Content-Length: + - '1726' + Content-Type: + - application/json + ParameterSetName: + - --resource-group --name --ssh-key-value + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: PUT + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002?api-version=2022-04-01 + response: + body: + string: "{\n \"id\": \"/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002\",\n + \ \"location\": \"westcentralus\",\n \"name\": \"cliakstest000002\",\n \"type\": + \"Microsoft.ContainerService/ManagedClusters\",\n \"properties\": {\n \"provisioningState\": + \"Creating\",\n \"powerState\": {\n \"code\": \"Running\"\n },\n \"kubernetesVersion\": + \"1.22.6\",\n \"dnsPrefix\": \"cliakstest-clitestl4ulryhrp-8ecadf\",\n \"fqdn\": + \"cliakstest-clitestl4ulryhrp-8ecadf-ba582b16.hcp.westcentralus.azmk8s.io\",\n + \ \"azurePortalFQDN\": \"cliakstest-clitestl4ulryhrp-8ecadf-ba582b16.portal.hcp.westcentralus.azmk8s.io\",\n + \ \"agentPoolProfiles\": [\n {\n \"name\": \"nodepool1\",\n \"count\": + 3,\n \"vmSize\": \"Standard_DS2_v2\",\n \"osDiskSizeGB\": 128,\n \"osDiskType\": + \"Managed\",\n \"kubeletDiskType\": \"OS\",\n \"workloadRuntime\": + \"OCIContainer\",\n \"maxPods\": 110,\n \"type\": \"VirtualMachineScaleSets\",\n + \ \"provisioningState\": \"Creating\",\n \"powerState\": {\n \"code\": + \"Running\"\n },\n \"orchestratorVersion\": \"1.22.6\",\n \"enableNodePublicIP\": + false,\n \"mode\": \"System\",\n \"enableEncryptionAtHost\": false,\n + \ \"enableUltraSSD\": false,\n \"osType\": \"Linux\",\n \"osSKU\": + \"Ubuntu\",\n \"nodeImageVersion\": \"AKSUbuntu-1804gen2containerd-2022.06.13\",\n + \ \"enableFIPS\": false\n }\n ],\n \"linuxProfile\": {\n \"adminUsername\": + \"azureuser\",\n \"ssh\": {\n \"publicKeys\": [\n {\n \"keyData\": + \"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQCbIg1guRHbI0lV11wWDt1r2cUdcNd27CJsg+SfgC7miZeubtwUhbsPdhMQsfDyhOWHq1+ZL0M+nJZV63d/1dhmhtgyOqejUwrPlzKhydsbrsdUor+JmNJDdW01v7BXHyuymT8G4s09jCasNOwiufbP/qp72ruu0bIA1nySsvlf9pCQAuFkAnVnf/rFhUlOkhtRpwcq8SUNY2zRHR/EKb/4NWY1JzR4sa3q2fWIJdrrX0DvLoa5g9bIEd4Df79ba7v+yiUBOS0zT2ll+z4g9izHK3EO5d8hL4jYxcjKs+wcslSYRWrascfscLgMlMGh0CdKeNTDjHpGPncaf3Z+FwwwjWeuiNBxv7bJo13/8B/098KlVDl4GZqsoBCEjPyJfV6hO0y/LkRGkk7oHWKgeWAfKtfLItRp00eZ4fcJNK9kCaSMmEugoZWcI7NGbZXzqFWqbpRI7NcDP9+WIQ+i9U5vqWsqd/zng4kbuAJ6UuKqIzB0upYrLShfQE3SAck8oaLhJqqq56VfDuASNpJKidV+zq27HfSBmbXnkR/5AK337dc3MXKJypoK/QPMLKUAP5XLPbs+NddJQV7EZXd29DLgp+fRIg3edpKdO7ZErWhv7d+3Kws+e1Y+ypmR2WIVSwVyBEUfgv2C8Ts9gnTF4pNcEY/S2aBicz5Ew2+jdyGNQQ== + test@example.com\\n\"\n }\n ]\n }\n },\n \"servicePrincipalProfile\": + {\n \"clientId\":\"00000000-0000-0000-0000-000000000001\"\n },\n \"nodeResourceGroup\": + \"MC_clitest000001_cliakstest000002_westcentralus\",\n \"enableRBAC\": true,\n + \ \"enablePodSecurityPolicy\": false,\n \"networkProfile\": {\n \"networkPlugin\": + \"kubenet\",\n \"loadBalancerSku\": \"standard\",\n \"loadBalancerProfile\": + {\n \"managedOutboundIPs\": {\n \"count\": 1\n }\n },\n \"podCidr\": + \"10.244.0.0/16\",\n \"serviceCidr\": \"10.0.0.0/16\",\n \"dnsServiceIP\": + \"10.0.0.10\",\n \"dockerBridgeCidr\": \"172.17.0.1/16\",\n \"outboundType\": + \"loadBalancer\"\n },\n \"maxAgentPools\": 100,\n \"disableLocalAccounts\": + false,\n \"securityProfile\": {}\n },\n \"identity\": {\n \"type\": + \"SystemAssigned\",\n \"principalId\":\"00000000-0000-0000-0000-000000000001\",\n + \ \"tenantId\": \"72f988bf-86f1-41af-91ab-2d7cd011db47\"\n },\n \"sku\": + {\n \"name\": \"Basic\",\n \"tier\": \"Free\"\n }\n }" + headers: + azure-asyncoperation: + - https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.ContainerService/locations/westcentralus/operations/85551c3a-b8ea-47af-91f8-55a304d669f5?api-version=2016-03-30 + cache-control: + - no-cache + content-length: + - '3143' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:07:19 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + x-content-type-options: + - nosniff + x-ms-ratelimit-remaining-subscription-writes: + - '1199' + status: + code: 201 + message: Created +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + CommandName: + - aks create + Connection: + - keep-alive + ParameterSetName: + - --resource-group --name --ssh-key-value + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.ContainerService/locations/westcentralus/operations/85551c3a-b8ea-47af-91f8-55a304d669f5?api-version=2016-03-30 + response: + body: + string: "{\n \"name\": \"3a1c5585-eab8-af47-91f8-55a304d669f5\",\n \"status\": + \"InProgress\",\n \"startTime\": \"2022-06-28T19:07:19.1Z\"\n }" + headers: + cache-control: + - no-cache + content-length: + - '120' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:07:50 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + CommandName: + - aks create + Connection: + - keep-alive + ParameterSetName: + - --resource-group --name --ssh-key-value + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.ContainerService/locations/westcentralus/operations/85551c3a-b8ea-47af-91f8-55a304d669f5?api-version=2016-03-30 + response: + body: + string: "{\n \"name\": \"3a1c5585-eab8-af47-91f8-55a304d669f5\",\n \"status\": + \"InProgress\",\n \"startTime\": \"2022-06-28T19:07:19.1Z\"\n }" + headers: + cache-control: + - no-cache + content-length: + - '120' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:08:19 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + CommandName: + - aks create + Connection: + - keep-alive + ParameterSetName: + - --resource-group --name --ssh-key-value + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.ContainerService/locations/westcentralus/operations/85551c3a-b8ea-47af-91f8-55a304d669f5?api-version=2016-03-30 + response: + body: + string: "{\n \"name\": \"3a1c5585-eab8-af47-91f8-55a304d669f5\",\n \"status\": + \"InProgress\",\n \"startTime\": \"2022-06-28T19:07:19.1Z\"\n }" + headers: + cache-control: + - no-cache + content-length: + - '120' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:08:50 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + CommandName: + - aks create + Connection: + - keep-alive + ParameterSetName: + - --resource-group --name --ssh-key-value + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.ContainerService/locations/westcentralus/operations/85551c3a-b8ea-47af-91f8-55a304d669f5?api-version=2016-03-30 + response: + body: + string: "{\n \"name\": \"3a1c5585-eab8-af47-91f8-55a304d669f5\",\n \"status\": + \"InProgress\",\n \"startTime\": \"2022-06-28T19:07:19.1Z\"\n }" + headers: + cache-control: + - no-cache + content-length: + - '120' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:09:19 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + CommandName: + - aks create + Connection: + - keep-alive + ParameterSetName: + - --resource-group --name --ssh-key-value + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.ContainerService/locations/westcentralus/operations/85551c3a-b8ea-47af-91f8-55a304d669f5?api-version=2016-03-30 + response: + body: + string: "{\n \"name\": \"3a1c5585-eab8-af47-91f8-55a304d669f5\",\n \"status\": + \"InProgress\",\n \"startTime\": \"2022-06-28T19:07:19.1Z\"\n }" + headers: + cache-control: + - no-cache + content-length: + - '120' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:09:49 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + CommandName: + - aks create + Connection: + - keep-alive + ParameterSetName: + - --resource-group --name --ssh-key-value + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.ContainerService/locations/westcentralus/operations/85551c3a-b8ea-47af-91f8-55a304d669f5?api-version=2016-03-30 + response: + body: + string: "{\n \"name\": \"3a1c5585-eab8-af47-91f8-55a304d669f5\",\n \"status\": + \"Succeeded\",\n \"startTime\": \"2022-06-28T19:07:19.1Z\",\n \"endTime\": + \"2022-06-28T19:10:17.4292417Z\"\n }" + headers: + cache-control: + - no-cache + content-length: + - '164' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:10:19 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + CommandName: + - aks create + Connection: + - keep-alive + ParameterSetName: + - --resource-group --name --ssh-key-value + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002?api-version=2022-04-01 + response: + body: + string: "{\n \"id\": \"/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002\",\n + \ \"location\": \"westcentralus\",\n \"name\": \"cliakstest000002\",\n \"type\": + \"Microsoft.ContainerService/ManagedClusters\",\n \"properties\": {\n \"provisioningState\": + \"Succeeded\",\n \"powerState\": {\n \"code\": \"Running\"\n },\n \"kubernetesVersion\": + \"1.22.6\",\n \"dnsPrefix\": \"cliakstest-clitestl4ulryhrp-8ecadf\",\n \"fqdn\": + \"cliakstest-clitestl4ulryhrp-8ecadf-ba582b16.hcp.westcentralus.azmk8s.io\",\n + \ \"azurePortalFQDN\": \"cliakstest-clitestl4ulryhrp-8ecadf-ba582b16.portal.hcp.westcentralus.azmk8s.io\",\n + \ \"agentPoolProfiles\": [\n {\n \"name\": \"nodepool1\",\n \"count\": + 3,\n \"vmSize\": \"Standard_DS2_v2\",\n \"osDiskSizeGB\": 128,\n \"osDiskType\": + \"Managed\",\n \"kubeletDiskType\": \"OS\",\n \"workloadRuntime\": + \"OCIContainer\",\n \"maxPods\": 110,\n \"type\": \"VirtualMachineScaleSets\",\n + \ \"provisioningState\": \"Succeeded\",\n \"powerState\": {\n \"code\": + \"Running\"\n },\n \"orchestratorVersion\": \"1.22.6\",\n \"enableNodePublicIP\": + false,\n \"mode\": \"System\",\n \"enableEncryptionAtHost\": false,\n + \ \"enableUltraSSD\": false,\n \"osType\": \"Linux\",\n \"osSKU\": + \"Ubuntu\",\n \"nodeImageVersion\": \"AKSUbuntu-1804gen2containerd-2022.06.13\",\n + \ \"enableFIPS\": false\n }\n ],\n \"linuxProfile\": {\n \"adminUsername\": + \"azureuser\",\n \"ssh\": {\n \"publicKeys\": [\n {\n \"keyData\": + \"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQCbIg1guRHbI0lV11wWDt1r2cUdcNd27CJsg+SfgC7miZeubtwUhbsPdhMQsfDyhOWHq1+ZL0M+nJZV63d/1dhmhtgyOqejUwrPlzKhydsbrsdUor+JmNJDdW01v7BXHyuymT8G4s09jCasNOwiufbP/qp72ruu0bIA1nySsvlf9pCQAuFkAnVnf/rFhUlOkhtRpwcq8SUNY2zRHR/EKb/4NWY1JzR4sa3q2fWIJdrrX0DvLoa5g9bIEd4Df79ba7v+yiUBOS0zT2ll+z4g9izHK3EO5d8hL4jYxcjKs+wcslSYRWrascfscLgMlMGh0CdKeNTDjHpGPncaf3Z+FwwwjWeuiNBxv7bJo13/8B/098KlVDl4GZqsoBCEjPyJfV6hO0y/LkRGkk7oHWKgeWAfKtfLItRp00eZ4fcJNK9kCaSMmEugoZWcI7NGbZXzqFWqbpRI7NcDP9+WIQ+i9U5vqWsqd/zng4kbuAJ6UuKqIzB0upYrLShfQE3SAck8oaLhJqqq56VfDuASNpJKidV+zq27HfSBmbXnkR/5AK337dc3MXKJypoK/QPMLKUAP5XLPbs+NddJQV7EZXd29DLgp+fRIg3edpKdO7ZErWhv7d+3Kws+e1Y+ypmR2WIVSwVyBEUfgv2C8Ts9gnTF4pNcEY/S2aBicz5Ew2+jdyGNQQ== + test@example.com\\n\"\n }\n ]\n }\n },\n \"servicePrincipalProfile\": + {\n \"clientId\":\"00000000-0000-0000-0000-000000000001\"\n },\n \"nodeResourceGroup\": + \"MC_clitest000001_cliakstest000002_westcentralus\",\n \"enableRBAC\": true,\n + \ \"enablePodSecurityPolicy\": false,\n \"networkProfile\": {\n \"networkPlugin\": + \"kubenet\",\n \"loadBalancerSku\": \"Standard\",\n \"loadBalancerProfile\": + {\n \"managedOutboundIPs\": {\n \"count\": 1\n },\n \"effectiveOutboundIPs\": + [\n {\n \"id\": \"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/MC_clitest000001_cliakstest000002_westcentralus/providers/Microsoft.Network/publicIPAddresses/cd6b0edc-885a-4a37-9c37-18ff4749030d\"\n + \ }\n ]\n },\n \"podCidr\": \"10.244.0.0/16\",\n \"serviceCidr\": + \"10.0.0.0/16\",\n \"dnsServiceIP\": \"10.0.0.10\",\n \"dockerBridgeCidr\": + \"172.17.0.1/16\",\n \"outboundType\": \"loadBalancer\"\n },\n \"maxAgentPools\": + 100,\n \"identityProfile\": {\n \"kubeletidentity\": {\n \"resourceId\": + \"/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/MC_clitest000001_cliakstest000002_westcentralus/providers/Microsoft.ManagedIdentity/userAssignedIdentities/cliakstest000002-agentpool\",\n + \ \"clientId\":\"00000000-0000-0000-0000-000000000001\",\n \"objectId\":\"00000000-0000-0000-0000-000000000001\"\n + \ }\n },\n \"disableLocalAccounts\": false,\n \"securityProfile\": + {}\n },\n \"identity\": {\n \"type\": \"SystemAssigned\",\n \"principalId\":\"00000000-0000-0000-0000-000000000001\",\n + \ \"tenantId\": \"72f988bf-86f1-41af-91ab-2d7cd011db47\"\n },\n \"sku\": + {\n \"name\": \"Basic\",\n \"tier\": \"Free\"\n }\n }" + headers: + cache-control: + - no-cache + content-length: + - '3808' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:10:20 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + CommandName: + - aks nodepool add + Connection: + - keep-alive + ParameterSetName: + - --resource-group --cluster-name --name --node-count + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002/agentPools?api-version=2022-04-01 + response: + body: + string: "{\n \"value\": [\n {\n \"id\": \"/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002/agentPools/nodepool1\",\n + \ \"name\": \"nodepool1\",\n \"type\": \"Microsoft.ContainerService/managedClusters/agentPools\",\n + \ \"properties\": {\n \"count\": 3,\n \"vmSize\": \"Standard_DS2_v2\",\n + \ \"osDiskSizeGB\": 128,\n \"osDiskType\": \"Managed\",\n \"kubeletDiskType\": + \"OS\",\n \"workloadRuntime\": \"OCIContainer\",\n \"maxPods\": 110,\n + \ \"type\": \"VirtualMachineScaleSets\",\n \"provisioningState\": \"Succeeded\",\n + \ \"powerState\": {\n \"code\": \"Running\"\n },\n \"orchestratorVersion\": + \"1.22.6\",\n \"enableNodePublicIP\": false,\n \"mode\": \"System\",\n + \ \"enableEncryptionAtHost\": false,\n \"enableUltraSSD\": false,\n + \ \"osType\": \"Linux\",\n \"osSKU\": \"Ubuntu\",\n \"nodeImageVersion\": + \"AKSUbuntu-1804gen2containerd-2022.06.13\",\n \"enableFIPS\": false\n + \ }\n }\n ]\n }" + headers: + cache-control: + - no-cache + content-length: + - '970' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:10:23 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: '{"properties": {"count": 2, "vmSize": "Standard_DS2_v2", "workloadRuntime": + "OCIContainer", "osType": "Linux", "scaleDownMode": "Delete", "mode": "User", + "upgradeSettings": {}, "enableNodePublicIP": false, "scaleSetPriority": "Regular", + "scaleSetEvictionPolicy": "Delete", "spotMaxPrice": -1.0, "nodeTaints": [], + "enableEncryptionAtHost": false, "enableUltraSSD": false, "enableFIPS": false}}' + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + CommandName: + - aks nodepool add + Connection: + - keep-alive + Content-Length: + - '392' + Content-Type: + - application/json + ParameterSetName: + - --resource-group --cluster-name --name --node-count + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: PUT + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002/agentPools/c000003?api-version=2022-04-01 + response: + body: + string: "{\n \"id\": \"/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002/agentPools/c000003\",\n + \ \"name\": \"c000003\",\n \"type\": \"Microsoft.ContainerService/managedClusters/agentPools\",\n + \ \"properties\": {\n \"count\": 2,\n \"vmSize\": \"Standard_DS2_v2\",\n + \ \"osDiskSizeGB\": 128,\n \"osDiskType\": \"Managed\",\n \"kubeletDiskType\": + \"OS\",\n \"workloadRuntime\": \"OCIContainer\",\n \"maxPods\": 110,\n + \ \"type\": \"VirtualMachineScaleSets\",\n \"scaleDownMode\": \"Delete\",\n + \ \"provisioningState\": \"Creating\",\n \"powerState\": {\n \"code\": + \"Running\"\n },\n \"orchestratorVersion\": \"1.22.6\",\n \"enableNodePublicIP\": + false,\n \"mode\": \"User\",\n \"enableEncryptionAtHost\": false,\n \"enableUltraSSD\": + false,\n \"osType\": \"Linux\",\n \"osSKU\": \"Ubuntu\",\n \"nodeImageVersion\": + \"AKSUbuntu-1804gen2containerd-2022.06.13\",\n \"upgradeSettings\": {},\n + \ \"enableFIPS\": false\n }\n }" + headers: + azure-asyncoperation: + - https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.ContainerService/locations/westcentralus/operations/6a3c494b-cdef-48a6-b026-38d7551678cd?api-version=2016-03-30 + cache-control: + - no-cache + content-length: + - '940' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:10:27 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + x-content-type-options: + - nosniff + x-ms-ratelimit-remaining-subscription-writes: + - '1199' + status: + code: 201 + message: Created +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + CommandName: + - aks nodepool add + Connection: + - keep-alive + ParameterSetName: + - --resource-group --cluster-name --name --node-count + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.ContainerService/locations/westcentralus/operations/6a3c494b-cdef-48a6-b026-38d7551678cd?api-version=2016-03-30 + response: + body: + string: "{\n \"name\": \"4b493c6a-efcd-a648-b026-38d7551678cd\",\n \"status\": + \"InProgress\",\n \"startTime\": \"2022-06-28T19:10:27.35Z\"\n }" + headers: + cache-control: + - no-cache + content-length: + - '121' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:10:57 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + CommandName: + - aks nodepool add + Connection: + - keep-alive + ParameterSetName: + - --resource-group --cluster-name --name --node-count + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.ContainerService/locations/westcentralus/operations/6a3c494b-cdef-48a6-b026-38d7551678cd?api-version=2016-03-30 + response: + body: + string: "{\n \"name\": \"4b493c6a-efcd-a648-b026-38d7551678cd\",\n \"status\": + \"InProgress\",\n \"startTime\": \"2022-06-28T19:10:27.35Z\"\n }" + headers: + cache-control: + - no-cache + content-length: + - '121' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:11:27 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + CommandName: + - aks nodepool add + Connection: + - keep-alive + ParameterSetName: + - --resource-group --cluster-name --name --node-count + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.ContainerService/locations/westcentralus/operations/6a3c494b-cdef-48a6-b026-38d7551678cd?api-version=2016-03-30 + response: + body: + string: "{\n \"name\": \"4b493c6a-efcd-a648-b026-38d7551678cd\",\n \"status\": + \"InProgress\",\n \"startTime\": \"2022-06-28T19:10:27.35Z\"\n }" + headers: + cache-control: + - no-cache + content-length: + - '121' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:11:57 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + CommandName: + - aks nodepool add + Connection: + - keep-alive + ParameterSetName: + - --resource-group --cluster-name --name --node-count + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.ContainerService/locations/westcentralus/operations/6a3c494b-cdef-48a6-b026-38d7551678cd?api-version=2016-03-30 + response: + body: + string: "{\n \"name\": \"4b493c6a-efcd-a648-b026-38d7551678cd\",\n \"status\": + \"InProgress\",\n \"startTime\": \"2022-06-28T19:10:27.35Z\"\n }" + headers: + cache-control: + - no-cache + content-length: + - '121' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:12:27 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + CommandName: + - aks nodepool add + Connection: + - keep-alive + ParameterSetName: + - --resource-group --cluster-name --name --node-count + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.ContainerService/locations/westcentralus/operations/6a3c494b-cdef-48a6-b026-38d7551678cd?api-version=2016-03-30 + response: + body: + string: "{\n \"name\": \"4b493c6a-efcd-a648-b026-38d7551678cd\",\n \"status\": + \"InProgress\",\n \"startTime\": \"2022-06-28T19:10:27.35Z\"\n }" + headers: + cache-control: + - no-cache + content-length: + - '121' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:12:58 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + CommandName: + - aks nodepool add + Connection: + - keep-alive + ParameterSetName: + - --resource-group --cluster-name --name --node-count + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.ContainerService/locations/westcentralus/operations/6a3c494b-cdef-48a6-b026-38d7551678cd?api-version=2016-03-30 + response: + body: + string: "{\n \"name\": \"4b493c6a-efcd-a648-b026-38d7551678cd\",\n \"status\": + \"InProgress\",\n \"startTime\": \"2022-06-28T19:10:27.35Z\"\n }" + headers: + cache-control: + - no-cache + content-length: + - '121' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:13:28 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + CommandName: + - aks nodepool add + Connection: + - keep-alive + ParameterSetName: + - --resource-group --cluster-name --name --node-count + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.ContainerService/locations/westcentralus/operations/6a3c494b-cdef-48a6-b026-38d7551678cd?api-version=2016-03-30 + response: + body: + string: "{\n \"name\": \"4b493c6a-efcd-a648-b026-38d7551678cd\",\n \"status\": + \"InProgress\",\n \"startTime\": \"2022-06-28T19:10:27.35Z\"\n }" + headers: + cache-control: + - no-cache + content-length: + - '121' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:13:58 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + CommandName: + - aks nodepool add + Connection: + - keep-alive + ParameterSetName: + - --resource-group --cluster-name --name --node-count + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.ContainerService/locations/westcentralus/operations/6a3c494b-cdef-48a6-b026-38d7551678cd?api-version=2016-03-30 + response: + body: + string: "{\n \"name\": \"4b493c6a-efcd-a648-b026-38d7551678cd\",\n \"status\": + \"Succeeded\",\n \"startTime\": \"2022-06-28T19:10:27.35Z\",\n \"endTime\": + \"2022-06-28T19:14:00.5257988Z\"\n }" + headers: + cache-control: + - no-cache + content-length: + - '165' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:14:28 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + CommandName: + - aks nodepool add + Connection: + - keep-alive + ParameterSetName: + - --resource-group --cluster-name --name --node-count + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002/agentPools/c000003?api-version=2022-04-01 + response: + body: + string: "{\n \"id\": \"/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002/agentPools/c000003\",\n + \ \"name\": \"c000003\",\n \"type\": \"Microsoft.ContainerService/managedClusters/agentPools\",\n + \ \"properties\": {\n \"count\": 2,\n \"vmSize\": \"Standard_DS2_v2\",\n + \ \"osDiskSizeGB\": 128,\n \"osDiskType\": \"Managed\",\n \"kubeletDiskType\": + \"OS\",\n \"workloadRuntime\": \"OCIContainer\",\n \"maxPods\": 110,\n + \ \"type\": \"VirtualMachineScaleSets\",\n \"scaleDownMode\": \"Delete\",\n + \ \"provisioningState\": \"Succeeded\",\n \"powerState\": {\n \"code\": + \"Running\"\n },\n \"orchestratorVersion\": \"1.22.6\",\n \"enableNodePublicIP\": + false,\n \"mode\": \"User\",\n \"enableEncryptionAtHost\": false,\n \"enableUltraSSD\": + false,\n \"osType\": \"Linux\",\n \"osSKU\": \"Ubuntu\",\n \"nodeImageVersion\": + \"AKSUbuntu-1804gen2containerd-2022.06.13\",\n \"upgradeSettings\": {},\n + \ \"enableFIPS\": false\n }\n }" + headers: + cache-control: + - no-cache + content-length: + - '941' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:14:28 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + CommandName: + - aks nodepool stop + Connection: + - keep-alive + ParameterSetName: + - --resource-group --cluster-name --nodepool-name + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002/agentPools?api-version=2022-04-01 + response: + body: + string: "{\n \"value\": [\n {\n \"id\": \"/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002/agentPools/c000003\",\n + \ \"name\": \"c000003\",\n \"type\": \"Microsoft.ContainerService/managedClusters/agentPools\",\n + \ \"properties\": {\n \"count\": 2,\n \"vmSize\": \"Standard_DS2_v2\",\n + \ \"osDiskSizeGB\": 128,\n \"osDiskType\": \"Managed\",\n \"kubeletDiskType\": + \"OS\",\n \"workloadRuntime\": \"OCIContainer\",\n \"maxPods\": 110,\n + \ \"type\": \"VirtualMachineScaleSets\",\n \"scaleDownMode\": \"Delete\",\n + \ \"provisioningState\": \"Succeeded\",\n \"powerState\": {\n \"code\": + \"Running\"\n },\n \"orchestratorVersion\": \"1.22.6\",\n \"enableNodePublicIP\": + false,\n \"mode\": \"User\",\n \"enableEncryptionAtHost\": false,\n + \ \"enableUltraSSD\": false,\n \"osType\": \"Linux\",\n \"osSKU\": + \"Ubuntu\",\n \"nodeImageVersion\": \"AKSUbuntu-1804gen2containerd-2022.06.13\",\n + \ \"upgradeSettings\": {},\n \"enableFIPS\": false\n }\n },\n + \ {\n \"id\": \"/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002/agentPools/nodepool1\",\n + \ \"name\": \"nodepool1\",\n \"type\": \"Microsoft.ContainerService/managedClusters/agentPools\",\n + \ \"properties\": {\n \"count\": 3,\n \"vmSize\": \"Standard_DS2_v2\",\n + \ \"osDiskSizeGB\": 128,\n \"osDiskType\": \"Managed\",\n \"kubeletDiskType\": + \"OS\",\n \"workloadRuntime\": \"OCIContainer\",\n \"maxPods\": 110,\n + \ \"type\": \"VirtualMachineScaleSets\",\n \"provisioningState\": \"Succeeded\",\n + \ \"powerState\": {\n \"code\": \"Running\"\n },\n \"orchestratorVersion\": + \"1.22.6\",\n \"enableNodePublicIP\": false,\n \"mode\": \"System\",\n + \ \"enableEncryptionAtHost\": false,\n \"enableUltraSSD\": false,\n + \ \"osType\": \"Linux\",\n \"osSKU\": \"Ubuntu\",\n \"nodeImageVersion\": + \"AKSUbuntu-1804gen2containerd-2022.06.13\",\n \"enableFIPS\": false\n + \ }\n }\n ]\n }" + headers: + cache-control: + - no-cache + content-length: + - '1974' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:14:31 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + CommandName: + - aks nodepool stop + Connection: + - keep-alive + ParameterSetName: + - --resource-group --cluster-name --nodepool-name + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002/agentPools/c000003?api-version=2022-04-01 + response: + body: + string: "{\n \"id\": \"/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002/agentPools/c000003\",\n + \ \"name\": \"c000003\",\n \"type\": \"Microsoft.ContainerService/managedClusters/agentPools\",\n + \ \"properties\": {\n \"count\": 2,\n \"vmSize\": \"Standard_DS2_v2\",\n + \ \"osDiskSizeGB\": 128,\n \"osDiskType\": \"Managed\",\n \"kubeletDiskType\": + \"OS\",\n \"workloadRuntime\": \"OCIContainer\",\n \"maxPods\": 110,\n + \ \"type\": \"VirtualMachineScaleSets\",\n \"scaleDownMode\": \"Delete\",\n + \ \"provisioningState\": \"Succeeded\",\n \"powerState\": {\n \"code\": + \"Running\"\n },\n \"orchestratorVersion\": \"1.22.6\",\n \"enableNodePublicIP\": + false,\n \"mode\": \"User\",\n \"enableEncryptionAtHost\": false,\n \"enableUltraSSD\": + false,\n \"osType\": \"Linux\",\n \"osSKU\": \"Ubuntu\",\n \"nodeImageVersion\": + \"AKSUbuntu-1804gen2containerd-2022.06.13\",\n \"upgradeSettings\": {},\n + \ \"enableFIPS\": false\n }\n }" + headers: + cache-control: + - no-cache + content-length: + - '941' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:14:31 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: '{"properties": {"count": 2, "vmSize": "Standard_DS2_v2", "osDiskSizeGB": + 128, "osDiskType": "Managed", "kubeletDiskType": "OS", "workloadRuntime": "OCIContainer", + "maxPods": 110, "osType": "Linux", "osSKU": "Ubuntu", "scaleDownMode": "Delete", + "type": "VirtualMachineScaleSets", "mode": "User", "orchestratorVersion": "1.22.6", + "upgradeSettings": {}, "powerState": {"code": "Stopped"}, "enableNodePublicIP": + false, "enableEncryptionAtHost": false, "enableUltraSSD": false, "enableFIPS": + false}}' + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + CommandName: + - aks nodepool stop + Connection: + - keep-alive + Content-Length: + - '494' + Content-Type: + - application/json + ParameterSetName: + - --resource-group --cluster-name --nodepool-name + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: PUT + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002/agentPools/c000003?api-version=2022-04-01 + response: + body: + string: "{\n \"id\": \"/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002/agentPools/c000003\",\n + \ \"name\": \"c000003\",\n \"type\": \"Microsoft.ContainerService/managedClusters/agentPools\",\n + \ \"properties\": {\n \"count\": 0,\n \"vmSize\": \"Standard_DS2_v2\",\n + \ \"osDiskSizeGB\": 128,\n \"osDiskType\": \"Managed\",\n \"kubeletDiskType\": + \"OS\",\n \"workloadRuntime\": \"OCIContainer\",\n \"maxPods\": 110,\n + \ \"type\": \"VirtualMachineScaleSets\",\n \"enableAutoScaling\": false,\n + \ \"scaleDownMode\": \"Delete\",\n \"provisioningState\": \"Stopping\",\n + \ \"powerState\": {\n \"code\": \"Stopped\"\n },\n \"orchestratorVersion\": + \"1.22.6\",\n \"enableNodePublicIP\": false,\n \"mode\": \"User\",\n \"enableEncryptionAtHost\": + false,\n \"enableUltraSSD\": false,\n \"osType\": \"Linux\",\n \"osSKU\": + \"Ubuntu\",\n \"nodeImageVersion\": \"AKSUbuntu-1804gen2containerd-2022.06.13\",\n + \ \"upgradeSettings\": {},\n \"enableFIPS\": false\n }\n }" + headers: + azure-asyncoperation: + - https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.ContainerService/locations/westcentralus/operations/f625721c-9950-40b7-b13b-3d399cfb68d8?api-version=2016-03-30 + cache-control: + - no-cache + content-length: + - '971' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:14:33 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + x-ms-ratelimit-remaining-subscription-writes: + - '1199' + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + CommandName: + - aks nodepool stop + Connection: + - keep-alive + ParameterSetName: + - --resource-group --cluster-name --nodepool-name + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.ContainerService/locations/westcentralus/operations/f625721c-9950-40b7-b13b-3d399cfb68d8?api-version=2016-03-30 + response: + body: + string: "{\n \"name\": \"1c7225f6-5099-b740-b13b-3d399cfb68d8\",\n \"status\": + \"InProgress\",\n \"startTime\": \"2022-06-28T19:14:33.98Z\"\n }" + headers: + cache-control: + - no-cache + content-length: + - '121' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:15:03 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + CommandName: + - aks nodepool stop + Connection: + - keep-alive + ParameterSetName: + - --resource-group --cluster-name --nodepool-name + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.ContainerService/locations/westcentralus/operations/f625721c-9950-40b7-b13b-3d399cfb68d8?api-version=2016-03-30 + response: + body: + string: "{\n \"name\": \"1c7225f6-5099-b740-b13b-3d399cfb68d8\",\n \"status\": + \"Succeeded\",\n \"startTime\": \"2022-06-28T19:14:33.98Z\",\n \"endTime\": + \"2022-06-28T19:15:11.3273142Z\"\n }" + headers: + cache-control: + - no-cache + content-length: + - '165' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:15:33 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + CommandName: + - aks nodepool stop + Connection: + - keep-alive + ParameterSetName: + - --resource-group --cluster-name --nodepool-name + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002/agentPools/c000003?api-version=2022-04-01 + response: + body: + string: "{\n \"id\": \"/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002/agentPools/c000003\",\n + \ \"name\": \"c000003\",\n \"type\": \"Microsoft.ContainerService/managedClusters/agentPools\",\n + \ \"properties\": {\n \"count\": 0,\n \"vmSize\": \"Standard_DS2_v2\",\n + \ \"osDiskSizeGB\": 128,\n \"osDiskType\": \"Managed\",\n \"kubeletDiskType\": + \"OS\",\n \"workloadRuntime\": \"OCIContainer\",\n \"maxPods\": 110,\n + \ \"type\": \"VirtualMachineScaleSets\",\n \"enableAutoScaling\": false,\n + \ \"scaleDownMode\": \"Delete\",\n \"provisioningState\": \"Succeeded\",\n + \ \"powerState\": {\n \"code\": \"Stopped\"\n },\n \"orchestratorVersion\": + \"1.22.6\",\n \"enableNodePublicIP\": false,\n \"mode\": \"User\",\n \"enableEncryptionAtHost\": + false,\n \"enableUltraSSD\": false,\n \"osType\": \"Linux\",\n \"osSKU\": + \"Ubuntu\",\n \"nodeImageVersion\": \"AKSUbuntu-1804gen2containerd-2022.06.13\",\n + \ \"upgradeSettings\": {},\n \"enableFIPS\": false\n }\n }" + headers: + cache-control: + - no-cache + content-length: + - '972' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:15:34 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + CommandName: + - aks nodepool start + Connection: + - keep-alive + ParameterSetName: + - --resource-group --cluster-name --nodepool-name + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002/agentPools?api-version=2022-04-01 + response: + body: + string: "{\n \"value\": [\n {\n \"id\": \"/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002/agentPools/c000003\",\n + \ \"name\": \"c000003\",\n \"type\": \"Microsoft.ContainerService/managedClusters/agentPools\",\n + \ \"properties\": {\n \"count\": 0,\n \"vmSize\": \"Standard_DS2_v2\",\n + \ \"osDiskSizeGB\": 128,\n \"osDiskType\": \"Managed\",\n \"kubeletDiskType\": + \"OS\",\n \"workloadRuntime\": \"OCIContainer\",\n \"maxPods\": 110,\n + \ \"type\": \"VirtualMachineScaleSets\",\n \"enableAutoScaling\": false,\n + \ \"scaleDownMode\": \"Delete\",\n \"provisioningState\": \"Succeeded\",\n + \ \"powerState\": {\n \"code\": \"Stopped\"\n },\n \"orchestratorVersion\": + \"1.22.6\",\n \"enableNodePublicIP\": false,\n \"mode\": \"User\",\n + \ \"enableEncryptionAtHost\": false,\n \"enableUltraSSD\": false,\n + \ \"osType\": \"Linux\",\n \"osSKU\": \"Ubuntu\",\n \"nodeImageVersion\": + \"AKSUbuntu-1804gen2containerd-2022.06.13\",\n \"upgradeSettings\": {},\n + \ \"enableFIPS\": false\n }\n },\n {\n \"id\": \"/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002/agentPools/nodepool1\",\n + \ \"name\": \"nodepool1\",\n \"type\": \"Microsoft.ContainerService/managedClusters/agentPools\",\n + \ \"properties\": {\n \"count\": 3,\n \"vmSize\": \"Standard_DS2_v2\",\n + \ \"osDiskSizeGB\": 128,\n \"osDiskType\": \"Managed\",\n \"kubeletDiskType\": + \"OS\",\n \"workloadRuntime\": \"OCIContainer\",\n \"maxPods\": 110,\n + \ \"type\": \"VirtualMachineScaleSets\",\n \"provisioningState\": \"Succeeded\",\n + \ \"powerState\": {\n \"code\": \"Running\"\n },\n \"orchestratorVersion\": + \"1.22.6\",\n \"enableNodePublicIP\": false,\n \"mode\": \"System\",\n + \ \"enableEncryptionAtHost\": false,\n \"enableUltraSSD\": false,\n + \ \"osType\": \"Linux\",\n \"osSKU\": \"Ubuntu\",\n \"nodeImageVersion\": + \"AKSUbuntu-1804gen2containerd-2022.06.13\",\n \"enableFIPS\": false\n + \ }\n }\n ]\n }" + headers: + cache-control: + - no-cache + content-length: + - '2007' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:15:36 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + CommandName: + - aks nodepool start + Connection: + - keep-alive + ParameterSetName: + - --resource-group --cluster-name --nodepool-name + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002/agentPools/c000003?api-version=2022-04-01 + response: + body: + string: "{\n \"id\": \"/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002/agentPools/c000003\",\n + \ \"name\": \"c000003\",\n \"type\": \"Microsoft.ContainerService/managedClusters/agentPools\",\n + \ \"properties\": {\n \"count\": 0,\n \"vmSize\": \"Standard_DS2_v2\",\n + \ \"osDiskSizeGB\": 128,\n \"osDiskType\": \"Managed\",\n \"kubeletDiskType\": + \"OS\",\n \"workloadRuntime\": \"OCIContainer\",\n \"maxPods\": 110,\n + \ \"type\": \"VirtualMachineScaleSets\",\n \"enableAutoScaling\": false,\n + \ \"scaleDownMode\": \"Delete\",\n \"provisioningState\": \"Succeeded\",\n + \ \"powerState\": {\n \"code\": \"Stopped\"\n },\n \"orchestratorVersion\": + \"1.22.6\",\n \"enableNodePublicIP\": false,\n \"mode\": \"User\",\n \"enableEncryptionAtHost\": + false,\n \"enableUltraSSD\": false,\n \"osType\": \"Linux\",\n \"osSKU\": + \"Ubuntu\",\n \"nodeImageVersion\": \"AKSUbuntu-1804gen2containerd-2022.06.13\",\n + \ \"upgradeSettings\": {},\n \"enableFIPS\": false\n }\n }" + headers: + cache-control: + - no-cache + content-length: + - '972' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:15:36 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: '{"properties": {"count": 0, "vmSize": "Standard_DS2_v2", "osDiskSizeGB": + 128, "osDiskType": "Managed", "kubeletDiskType": "OS", "workloadRuntime": "OCIContainer", + "maxPods": 110, "osType": "Linux", "osSKU": "Ubuntu", "enableAutoScaling": false, + "scaleDownMode": "Delete", "type": "VirtualMachineScaleSets", "mode": "User", + "orchestratorVersion": "1.22.6", "upgradeSettings": {}, "powerState": {"code": + "Running"}, "enableNodePublicIP": false, "enableEncryptionAtHost": false, "enableUltraSSD": + false, "enableFIPS": false}}' + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + CommandName: + - aks nodepool start + Connection: + - keep-alive + Content-Length: + - '522' + Content-Type: + - application/json + ParameterSetName: + - --resource-group --cluster-name --nodepool-name + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: PUT + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002/agentPools/c000003?api-version=2022-04-01 + response: + body: + string: "{\n \"id\": \"/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002/agentPools/c000003\",\n + \ \"name\": \"c000003\",\n \"type\": \"Microsoft.ContainerService/managedClusters/agentPools\",\n + \ \"properties\": {\n \"count\": 2,\n \"vmSize\": \"Standard_DS2_v2\",\n + \ \"osDiskSizeGB\": 128,\n \"osDiskType\": \"Managed\",\n \"kubeletDiskType\": + \"OS\",\n \"workloadRuntime\": \"OCIContainer\",\n \"maxPods\": 110,\n + \ \"type\": \"VirtualMachineScaleSets\",\n \"enableAutoScaling\": false,\n + \ \"scaleDownMode\": \"Delete\",\n \"provisioningState\": \"Starting\",\n + \ \"powerState\": {\n \"code\": \"Running\"\n },\n \"orchestratorVersion\": + \"1.22.6\",\n \"enableNodePublicIP\": false,\n \"mode\": \"User\",\n \"enableEncryptionAtHost\": + false,\n \"enableUltraSSD\": false,\n \"osType\": \"Linux\",\n \"osSKU\": + \"Ubuntu\",\n \"nodeImageVersion\": \"AKSUbuntu-1804gen2containerd-2022.06.13\",\n + \ \"upgradeSettings\": {},\n \"enableFIPS\": false\n }\n }" + headers: + azure-asyncoperation: + - https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.ContainerService/locations/westcentralus/operations/26c79263-9a49-46b1-8079-d171c996831e?api-version=2016-03-30 + cache-control: + - no-cache + content-length: + - '971' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:15:38 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + x-ms-ratelimit-remaining-subscription-writes: + - '1199' + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + CommandName: + - aks nodepool start + Connection: + - keep-alive + ParameterSetName: + - --resource-group --cluster-name --nodepool-name + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.ContainerService/locations/westcentralus/operations/26c79263-9a49-46b1-8079-d171c996831e?api-version=2016-03-30 + response: + body: + string: "{\n \"name\": \"6392c726-499a-b146-8079-d171c996831e\",\n \"status\": + \"InProgress\",\n \"startTime\": \"2022-06-28T19:15:39.73Z\"\n }" + headers: + cache-control: + - no-cache + content-length: + - '121' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:16:09 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + CommandName: + - aks nodepool start + Connection: + - keep-alive + ParameterSetName: + - --resource-group --cluster-name --nodepool-name + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.ContainerService/locations/westcentralus/operations/26c79263-9a49-46b1-8079-d171c996831e?api-version=2016-03-30 + response: + body: + string: "{\n \"name\": \"6392c726-499a-b146-8079-d171c996831e\",\n \"status\": + \"InProgress\",\n \"startTime\": \"2022-06-28T19:15:39.73Z\"\n }" + headers: + cache-control: + - no-cache + content-length: + - '121' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:16:39 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + CommandName: + - aks nodepool start + Connection: + - keep-alive + ParameterSetName: + - --resource-group --cluster-name --nodepool-name + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.ContainerService/locations/westcentralus/operations/26c79263-9a49-46b1-8079-d171c996831e?api-version=2016-03-30 + response: + body: + string: "{\n \"name\": \"6392c726-499a-b146-8079-d171c996831e\",\n \"status\": + \"InProgress\",\n \"startTime\": \"2022-06-28T19:15:39.73Z\"\n }" + headers: + cache-control: + - no-cache + content-length: + - '121' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:17:09 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + CommandName: + - aks nodepool start + Connection: + - keep-alive + ParameterSetName: + - --resource-group --cluster-name --nodepool-name + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.ContainerService/locations/westcentralus/operations/26c79263-9a49-46b1-8079-d171c996831e?api-version=2016-03-30 + response: + body: + string: "{\n \"name\": \"6392c726-499a-b146-8079-d171c996831e\",\n \"status\": + \"Succeeded\",\n \"startTime\": \"2022-06-28T19:15:39.73Z\",\n \"endTime\": + \"2022-06-28T19:17:13.7581088Z\"\n }" + headers: + cache-control: + - no-cache + content-length: + - '165' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:17:39 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + CommandName: + - aks nodepool start + Connection: + - keep-alive + ParameterSetName: + - --resource-group --cluster-name --nodepool-name + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/16.3.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002/agentPools/c000003?api-version=2022-04-01 + response: + body: + string: "{\n \"id\": \"/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002/agentPools/c000003\",\n + \ \"name\": \"c000003\",\n \"type\": \"Microsoft.ContainerService/managedClusters/agentPools\",\n + \ \"properties\": {\n \"count\": 2,\n \"vmSize\": \"Standard_DS2_v2\",\n + \ \"osDiskSizeGB\": 128,\n \"osDiskType\": \"Managed\",\n \"kubeletDiskType\": + \"OS\",\n \"workloadRuntime\": \"OCIContainer\",\n \"maxPods\": 110,\n + \ \"type\": \"VirtualMachineScaleSets\",\n \"enableAutoScaling\": false,\n + \ \"scaleDownMode\": \"Delete\",\n \"provisioningState\": \"Succeeded\",\n + \ \"powerState\": {\n \"code\": \"Running\"\n },\n \"orchestratorVersion\": + \"1.22.6\",\n \"enableNodePublicIP\": false,\n \"mode\": \"User\",\n \"enableEncryptionAtHost\": + false,\n \"enableUltraSSD\": false,\n \"osType\": \"Linux\",\n \"osSKU\": + \"Ubuntu\",\n \"nodeImageVersion\": \"AKSUbuntu-1804gen2containerd-2022.06.13\",\n + \ \"upgradeSettings\": {},\n \"enableFIPS\": false\n }\n }" + headers: + cache-control: + - no-cache + content-length: + - '972' + content-type: + - application/json + date: + - Tue, 28 Jun 2022 19:17:40 GMT + expires: + - '-1' + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + transfer-encoding: + - chunked + vary: + - Accept-Encoding + x-content-type-options: + - nosniff + status: + code: 200 + message: OK +- request: + body: null + headers: + Accept: + - application/json + Accept-Encoding: + - gzip, deflate + CommandName: + - aks delete + Connection: + - keep-alive + Content-Length: + - '0' + ParameterSetName: + - -g -n --yes --no-wait + User-Agent: + - AZURECLI/2.37.0 azsdk-python-azure-mgmt-containerservice/19.1.0 Python/3.7.9 + (Darwin-21.5.0-x86_64-i386-64bit) + method: DELETE + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clitest000001/providers/Microsoft.ContainerService/managedClusters/cliakstest000002?api-version=2022-04-01 + response: + body: + string: '' + headers: + azure-asyncoperation: + - https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.ContainerService/locations/westcentralus/operations/a47c84b3-c6b2-4fb1-be96-15ff94e459fe?api-version=2016-03-30 + cache-control: + - no-cache + content-length: + - '0' + date: + - Tue, 28 Jun 2022 19:17:42 GMT + expires: + - '-1' + location: + - https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.ContainerService/locations/westcentralus/operationresults/a47c84b3-c6b2-4fb1-be96-15ff94e459fe?api-version=2016-03-30 + pragma: + - no-cache + server: + - nginx + strict-transport-security: + - max-age=31536000; includeSubDomains + x-content-type-options: + - nosniff + x-ms-ratelimit-remaining-subscription-deletes: + - '14999' + status: + code: 202 + message: Accepted +version: 1 diff --git a/src/azure-cli/azure/cli/command_modules/acs/tests/latest/test_aks_commands.py b/src/azure-cli/azure/cli/command_modules/acs/tests/latest/test_aks_commands.py index 5236b7f16ff..802cbc17849 100644 --- a/src/azure-cli/azure/cli/command_modules/acs/tests/latest/test_aks_commands.py +++ b/src/azure-cli/azure/cli/command_modules/acs/tests/latest/test_aks_commands.py @@ -5201,6 +5201,39 @@ def test_aks_nodepool_autoscaler_then_update(self, resource_group, resource_grou # delete self.cmd( 'aks delete -g {resource_group} -n {name} --yes --no-wait', checks=[self.is_empty()]) + + @AllowLargeResponse() + @AKSCustomResourceGroupPreparer(random_name_length=17, name_prefix='clitest', location='westcentralus') + def test_aks_nodepool_stop_and_start(self, resource_group, resource_group_location): + aks_name = self.create_random_name('cliakstest', 16) + nodepool_name = self.create_random_name('c', 6) + self.kwargs.update({ + 'resource_group': resource_group, + 'name': aks_name, + 'nodepool_name' : nodepool_name, + 'ssh_key_value': self.generate_ssh_keys() + }) + + # create aks cluster + create_cmd = 'aks create --resource-group={resource_group} --name={name} --ssh-key-value={ssh_key_value}' + self.cmd(create_cmd, checks=[ + self.check('provisioningState', 'Succeeded'), + ]) + # add nodepool + self.cmd('aks nodepool add --resource-group={resource_group} --cluster-name={name} --name={nodepool_name} --node-count=2', checks=[ + self.check('provisioningState', 'Succeeded') + ]) + # stop nodepool + self.cmd('aks nodepool stop --resource-group={resource_group} --cluster-name={name} --nodepool-name={nodepool_name}', checks=[ + self.check('powerState.code', 'Stopped') + ]) + #start nodepool + self.cmd('aks nodepool start --resource-group={resource_group} --cluster-name={name} --nodepool-name={nodepool_name}', checks=[ + self.check('powerState.code', 'Running') + ]) + # delete AKS cluster + self.cmd( + 'aks delete -g {resource_group} -n {name} --yes --no-wait', checks=[self.is_empty()]) @AllowLargeResponse() @AKSCustomResourceGroupPreparer(random_name_length=17, name_prefix='clitest', location='westus2')