Class: Azure::ContainerService::Mgmt::V2020_12_01::ManagedClusters
- Inherits:
-
Object
- Object
- Azure::ContainerService::Mgmt::V2020_12_01::ManagedClusters
- Includes:
- MsRestAzure
- Defined in:
- lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb
Overview
The Container Service Client.
Instance Attribute Summary collapse
-
#client ⇒ ContainerServiceClient
readonly
Reference to the ContainerServiceClient.
Instance Method Summary collapse
-
#begin_create_or_update(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ ManagedCluster
Creates or updates a managed cluster.
-
#begin_create_or_update_async(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ Concurrent::Promise
Creates or updates a managed cluster.
-
#begin_create_or_update_with_http_info(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Creates or updates a managed cluster.
-
#begin_delete(resource_group_name, resource_name, custom_headers: nil) ⇒ Object
Deletes a managed cluster.
-
#begin_delete_async(resource_group_name, resource_name, custom_headers: nil) ⇒ Concurrent::Promise
Deletes a managed cluster.
-
#begin_delete_with_http_info(resource_group_name, resource_name, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Deletes a managed cluster.
-
#begin_reset_aadprofile(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ Object
Reset AAD Profile of a managed cluster.
-
#begin_reset_aadprofile_async(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ Concurrent::Promise
Reset AAD Profile of a managed cluster.
-
#begin_reset_aadprofile_with_http_info(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Reset AAD Profile of a managed cluster.
-
#begin_reset_service_principal_profile(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ Object
Reset Service Principal Profile of a managed cluster.
-
#begin_reset_service_principal_profile_async(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ Concurrent::Promise
Reset Service Principal Profile of a managed cluster.
-
#begin_reset_service_principal_profile_with_http_info(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Reset Service Principal Profile of a managed cluster.
-
#begin_rotate_cluster_certificates(resource_group_name, resource_name, custom_headers: nil) ⇒ Object
Rotate certificates of a managed cluster.
-
#begin_rotate_cluster_certificates_async(resource_group_name, resource_name, custom_headers: nil) ⇒ Concurrent::Promise
Rotate certificates of a managed cluster.
-
#begin_rotate_cluster_certificates_with_http_info(resource_group_name, resource_name, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Rotate certificates of a managed cluster.
-
#begin_start(resource_group_name, resource_name, custom_headers: nil) ⇒ Object
Start Managed Cluster.
-
#begin_start_async(resource_group_name, resource_name, custom_headers: nil) ⇒ Concurrent::Promise
Start Managed Cluster.
-
#begin_start_with_http_info(resource_group_name, resource_name, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Start Managed Cluster.
-
#begin_stop(resource_group_name, resource_name, custom_headers: nil) ⇒ Object
Stop Managed Cluster.
-
#begin_stop_async(resource_group_name, resource_name, custom_headers: nil) ⇒ Concurrent::Promise
Stop Managed Cluster.
-
#begin_stop_with_http_info(resource_group_name, resource_name, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Stop Managed Cluster.
-
#begin_update_tags(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ ManagedCluster
Updates tags on a managed cluster.
-
#begin_update_tags_async(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ Concurrent::Promise
Updates tags on a managed cluster.
-
#begin_update_tags_with_http_info(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Updates tags on a managed cluster.
-
#create_or_update(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ ManagedCluster
Creates or updates a managed cluster.
-
#create_or_update_async(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ Concurrent::Promise
Update a Managed Cluster operation.
-
#delete(resource_group_name, resource_name, custom_headers: nil) ⇒ Object
Deletes a managed cluster.
-
#delete_async(resource_group_name, resource_name, custom_headers: nil) ⇒ Concurrent::Promise
will be added to the HTTP request.
-
#get(resource_group_name, resource_name, custom_headers: nil) ⇒ ManagedCluster
Gets a managed cluster.
-
#get_access_profile(resource_group_name, resource_name, role_name, custom_headers: nil) ⇒ ManagedClusterAccessProfile
Gets an access profile of a managed cluster.
-
#get_access_profile_async(resource_group_name, resource_name, role_name, custom_headers: nil) ⇒ Concurrent::Promise
Gets an access profile of a managed cluster.
-
#get_access_profile_with_http_info(resource_group_name, resource_name, role_name, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Gets an access profile of a managed cluster.
-
#get_async(resource_group_name, resource_name, custom_headers: nil) ⇒ Concurrent::Promise
Gets a managed cluster.
-
#get_upgrade_profile(resource_group_name, resource_name, custom_headers: nil) ⇒ ManagedClusterUpgradeProfile
Gets upgrade profile for a managed cluster.
-
#get_upgrade_profile_async(resource_group_name, resource_name, custom_headers: nil) ⇒ Concurrent::Promise
Gets upgrade profile for a managed cluster.
-
#get_upgrade_profile_with_http_info(resource_group_name, resource_name, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Gets upgrade profile for a managed cluster.
-
#get_with_http_info(resource_group_name, resource_name, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Gets a managed cluster.
-
#initialize(client) ⇒ ManagedClusters
constructor
Creates and initializes a new instance of the ManagedClusters class.
-
#list(custom_headers: nil) ⇒ Array<ManagedCluster>
Gets a list of managed clusters in the specified subscription.
-
#list_as_lazy(custom_headers: nil) ⇒ ManagedClusterListResult
Gets a list of managed clusters in the specified subscription.
-
#list_async(custom_headers: nil) ⇒ Concurrent::Promise
Gets a list of managed clusters in the specified subscription.
-
#list_by_resource_group(resource_group_name, custom_headers: nil) ⇒ Array<ManagedCluster>
Lists managed clusters in the specified subscription and resource group.
-
#list_by_resource_group_as_lazy(resource_group_name, custom_headers: nil) ⇒ ManagedClusterListResult
Lists managed clusters in the specified subscription and resource group.
-
#list_by_resource_group_async(resource_group_name, custom_headers: nil) ⇒ Concurrent::Promise
Lists managed clusters in the specified subscription and resource group.
-
#list_by_resource_group_next(next_page_link, custom_headers: nil) ⇒ ManagedClusterListResult
Lists managed clusters in the specified subscription and resource group.
-
#list_by_resource_group_next_async(next_page_link, custom_headers: nil) ⇒ Concurrent::Promise
Lists managed clusters in the specified subscription and resource group.
-
#list_by_resource_group_next_with_http_info(next_page_link, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Lists managed clusters in the specified subscription and resource group.
-
#list_by_resource_group_with_http_info(resource_group_name, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Lists managed clusters in the specified subscription and resource group.
-
#list_cluster_admin_credentials(resource_group_name, resource_name, custom_headers: nil) ⇒ CredentialResults
Gets cluster admin credential of a managed cluster.
-
#list_cluster_admin_credentials_async(resource_group_name, resource_name, custom_headers: nil) ⇒ Concurrent::Promise
Gets cluster admin credential of a managed cluster.
-
#list_cluster_admin_credentials_with_http_info(resource_group_name, resource_name, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Gets cluster admin credential of a managed cluster.
-
#list_cluster_monitoring_user_credentials(resource_group_name, resource_name, custom_headers: nil) ⇒ CredentialResults
Gets cluster monitoring user credential of a managed cluster.
-
#list_cluster_monitoring_user_credentials_async(resource_group_name, resource_name, custom_headers: nil) ⇒ Concurrent::Promise
Gets cluster monitoring user credential of a managed cluster.
-
#list_cluster_monitoring_user_credentials_with_http_info(resource_group_name, resource_name, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Gets cluster monitoring user credential of a managed cluster.
-
#list_cluster_user_credentials(resource_group_name, resource_name, custom_headers: nil) ⇒ CredentialResults
Gets cluster user credential of a managed cluster.
-
#list_cluster_user_credentials_async(resource_group_name, resource_name, custom_headers: nil) ⇒ Concurrent::Promise
Gets cluster user credential of a managed cluster.
-
#list_cluster_user_credentials_with_http_info(resource_group_name, resource_name, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Gets cluster user credential of a managed cluster.
-
#list_next(next_page_link, custom_headers: nil) ⇒ ManagedClusterListResult
Gets a list of managed clusters in the specified subscription.
-
#list_next_async(next_page_link, custom_headers: nil) ⇒ Concurrent::Promise
Gets a list of managed clusters in the specified subscription.
-
#list_next_with_http_info(next_page_link, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Gets a list of managed clusters in the specified subscription.
-
#list_with_http_info(custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Gets a list of managed clusters in the specified subscription.
-
#reset_aadprofile(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ Object
Reset AAD Profile of a managed cluster.
-
#reset_aadprofile_async(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ Concurrent::Promise
AAD Profile operation for a Managed Cluster.
-
#reset_service_principal_profile(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ Object
Reset Service Principal Profile of a managed cluster.
-
#reset_service_principal_profile_async(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ Concurrent::Promise
to the Reset Service Principal Profile operation for a Managed Cluster.
-
#rotate_cluster_certificates(resource_group_name, resource_name, custom_headers: nil) ⇒ Object
Rotate certificates of a managed cluster.
-
#rotate_cluster_certificates_async(resource_group_name, resource_name, custom_headers: nil) ⇒ Concurrent::Promise
will be added to the HTTP request.
-
#start(resource_group_name, resource_name, custom_headers: nil) ⇒ Object
Start Managed Cluster.
-
#start_async(resource_group_name, resource_name, custom_headers: nil) ⇒ Concurrent::Promise
will be added to the HTTP request.
-
#stop(resource_group_name, resource_name, custom_headers: nil) ⇒ Object
Stop Managed Cluster.
-
#stop_async(resource_group_name, resource_name, custom_headers: nil) ⇒ Concurrent::Promise
will be added to the HTTP request.
-
#update_tags(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ ManagedCluster
Updates tags on a managed cluster.
-
#update_tags_async(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ Concurrent::Promise
Cluster Tags operation.
Constructor Details
#initialize(client) ⇒ ManagedClusters
Creates and initializes a new instance of the ManagedClusters class.
17 18 19 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 17 def initialize(client) @client = client end |
Instance Attribute Details
#client ⇒ ContainerServiceClient (readonly)
Returns reference to the ContainerServiceClient.
22 23 24 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 22 def client @client end |
Instance Method Details
#begin_create_or_update(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ ManagedCluster
Creates or updates a managed cluster.
Creates or updates a managed cluster with the specified configuration for agents and Kubernetes version.
Update a Managed Cluster operation. will be added to the HTTP request.
1243 1244 1245 1246 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1243 def begin_create_or_update(resource_group_name, resource_name, parameters, custom_headers:nil) response = begin_create_or_update_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers).value! response.body unless response.nil? end |
#begin_create_or_update_async(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ Concurrent::Promise
Creates or updates a managed cluster.
Creates or updates a managed cluster with the specified configuration for agents and Kubernetes version.
Update a Managed Cluster operation. to the HTTP request.
1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1282 def begin_create_or_update_async(resource_group_name, resource_name, parameters, custom_headers:nil) fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1 fail ArgumentError, 'resource_name is nil' if resource_name.nil? fail ArgumentError, "'resource_name' should satisfy the constraint - 'MaxLength': '63'" if !resource_name.nil? && resource_name.length > 63 fail ArgumentError, "'resource_name' should satisfy the constraint - 'MinLength': '1'" if !resource_name.nil? && resource_name.length < 1 fail ArgumentError, "'resource_name' should satisfy the constraint - 'Pattern': '^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'" if !resource_name.nil? && resource_name.match(Regexp.new('^^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$$')).nil? fail ArgumentError, 'parameters is nil' if parameters.nil? request_headers = {} request_headers['Content-Type'] = 'application/json; charset=utf-8' # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? # Serialize Request request_mapper = Azure::ContainerService::Mgmt::V2020_12_01::Models::ManagedCluster.mapper() request_content = @client.serialize(request_mapper, parameters) request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'resourceName' => resource_name}, query_params: {'api-version' => @client.api_version}, body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:put, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 200 || status_code == 201 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil? result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil? # Deserialize Response if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) result_mapper = Azure::ContainerService::Mgmt::V2020_12_01::Models::ManagedCluster.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e., e.backtrace, result) end end # Deserialize Response if status_code == 201 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) result_mapper = Azure::ContainerService::Mgmt::V2020_12_01::Models::ManagedCluster.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e., e.backtrace, result) end end result end promise.execute end |
#begin_create_or_update_with_http_info(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Creates or updates a managed cluster.
Creates or updates a managed cluster with the specified configuration for agents and Kubernetes version.
Update a Managed Cluster operation. will be added to the HTTP request.
1263 1264 1265 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1263 def begin_create_or_update_with_http_info(resource_group_name, resource_name, parameters, custom_headers:nil) begin_create_or_update_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers).value! end |
#begin_delete(resource_group_name, resource_name, custom_headers: nil) ⇒ Object
Deletes a managed cluster.
Deletes the managed cluster with a specified resource group and name.
will be added to the HTTP request.
1488 1489 1490 1491 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1488 def begin_delete(resource_group_name, resource_name, custom_headers:nil) response = begin_delete_async(resource_group_name, resource_name, custom_headers:custom_headers).value! nil end |
#begin_delete_async(resource_group_name, resource_name, custom_headers: nil) ⇒ Concurrent::Promise
Deletes a managed cluster.
Deletes the managed cluster with a specified resource group and name.
to the HTTP request.
1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1521 def begin_delete_async(resource_group_name, resource_name, custom_headers:nil) fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1 fail ArgumentError, 'resource_name is nil' if resource_name.nil? fail ArgumentError, "'resource_name' should satisfy the constraint - 'MaxLength': '63'" if !resource_name.nil? && resource_name.length > 63 fail ArgumentError, "'resource_name' should satisfy the constraint - 'MinLength': '1'" if !resource_name.nil? && resource_name.length < 1 fail ArgumentError, "'resource_name' should satisfy the constraint - 'Pattern': '^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'" if !resource_name.nil? && resource_name.match(Regexp.new('^^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$$')).nil? request_headers = {} request_headers['Content-Type'] = 'application/json; charset=utf-8' # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'resourceName' => resource_name}, query_params: {'api-version' => @client.api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:delete, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 202 || status_code == 204 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil? result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil? result end promise.execute end |
#begin_delete_with_http_info(resource_group_name, resource_name, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Deletes a managed cluster.
Deletes the managed cluster with a specified resource group and name.
will be added to the HTTP request.
1505 1506 1507 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1505 def begin_delete_with_http_info(resource_group_name, resource_name, custom_headers:nil) begin_delete_async(resource_group_name, resource_name, custom_headers:custom_headers).value! end |
#begin_reset_aadprofile(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ Object
Reset AAD Profile of a managed cluster.
Update the AAD Profile for a managed cluster.
AAD Profile operation for a Managed Cluster. will be added to the HTTP request.
1690 1691 1692 1693 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1690 def begin_reset_aadprofile(resource_group_name, resource_name, parameters, custom_headers:nil) response = begin_reset_aadprofile_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers).value! nil end |
#begin_reset_aadprofile_async(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ Concurrent::Promise
Reset AAD Profile of a managed cluster.
Update the AAD Profile for a managed cluster.
AAD Profile operation for a Managed Cluster. to the HTTP request.
1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1727 def begin_reset_aadprofile_async(resource_group_name, resource_name, parameters, custom_headers:nil) fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1 fail ArgumentError, 'resource_name is nil' if resource_name.nil? fail ArgumentError, "'resource_name' should satisfy the constraint - 'MaxLength': '63'" if !resource_name.nil? && resource_name.length > 63 fail ArgumentError, "'resource_name' should satisfy the constraint - 'MinLength': '1'" if !resource_name.nil? && resource_name.length < 1 fail ArgumentError, "'resource_name' should satisfy the constraint - 'Pattern': '^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'" if !resource_name.nil? && resource_name.match(Regexp.new('^^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$$')).nil? fail ArgumentError, 'parameters is nil' if parameters.nil? request_headers = {} request_headers['Content-Type'] = 'application/json; charset=utf-8' # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? # Serialize Request request_mapper = Azure::ContainerService::Mgmt::V2020_12_01::Models::ManagedClusterAADProfile.mapper() request_content = @client.serialize(request_mapper, parameters) request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}/resetAADProfile' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'resourceName' => resource_name}, query_params: {'api-version' => @client.api_version}, body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:post, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 200 || status_code == 202 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil? result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil? result end promise.execute end |
#begin_reset_aadprofile_with_http_info(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Reset AAD Profile of a managed cluster.
Update the AAD Profile for a managed cluster.
AAD Profile operation for a Managed Cluster. will be added to the HTTP request.
1709 1710 1711 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1709 def begin_reset_aadprofile_with_http_info(resource_group_name, resource_name, parameters, custom_headers:nil) begin_reset_aadprofile_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers).value! end |
#begin_reset_service_principal_profile(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ Object
Reset Service Principal Profile of a managed cluster.
Update the service principal Profile for a managed cluster.
to the Reset Service Principal Profile operation for a Managed Cluster. will be added to the HTTP request.
1583 1584 1585 1586 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1583 def begin_reset_service_principal_profile(resource_group_name, resource_name, parameters, custom_headers:nil) response = begin_reset_service_principal_profile_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers).value! nil end |
#begin_reset_service_principal_profile_async(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ Concurrent::Promise
Reset Service Principal Profile of a managed cluster.
Update the service principal Profile for a managed cluster.
to the Reset Service Principal Profile operation for a Managed Cluster. to the HTTP request.
1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1620 def begin_reset_service_principal_profile_async(resource_group_name, resource_name, parameters, custom_headers:nil) fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1 fail ArgumentError, 'resource_name is nil' if resource_name.nil? fail ArgumentError, "'resource_name' should satisfy the constraint - 'MaxLength': '63'" if !resource_name.nil? && resource_name.length > 63 fail ArgumentError, "'resource_name' should satisfy the constraint - 'MinLength': '1'" if !resource_name.nil? && resource_name.length < 1 fail ArgumentError, "'resource_name' should satisfy the constraint - 'Pattern': '^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'" if !resource_name.nil? && resource_name.match(Regexp.new('^^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$$')).nil? fail ArgumentError, 'parameters is nil' if parameters.nil? request_headers = {} request_headers['Content-Type'] = 'application/json; charset=utf-8' # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? # Serialize Request request_mapper = Azure::ContainerService::Mgmt::V2020_12_01::Models::ManagedClusterServicePrincipalProfile.mapper() request_content = @client.serialize(request_mapper, parameters) request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}/resetServicePrincipalProfile' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'resourceName' => resource_name}, query_params: {'api-version' => @client.api_version}, body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:post, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 200 || status_code == 202 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil? result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil? result end promise.execute end |
#begin_reset_service_principal_profile_with_http_info(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Reset Service Principal Profile of a managed cluster.
Update the service principal Profile for a managed cluster.
to the Reset Service Principal Profile operation for a Managed Cluster. will be added to the HTTP request.
1602 1603 1604 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1602 def begin_reset_service_principal_profile_with_http_info(resource_group_name, resource_name, parameters, custom_headers:nil) begin_reset_service_principal_profile_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers).value! end |
#begin_rotate_cluster_certificates(resource_group_name, resource_name, custom_headers: nil) ⇒ Object
Rotate certificates of a managed cluster.
Rotate certificates of a managed cluster.
will be added to the HTTP request.
1795 1796 1797 1798 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1795 def begin_rotate_cluster_certificates(resource_group_name, resource_name, custom_headers:nil) response = begin_rotate_cluster_certificates_async(resource_group_name, resource_name, custom_headers:custom_headers).value! nil end |
#begin_rotate_cluster_certificates_async(resource_group_name, resource_name, custom_headers: nil) ⇒ Concurrent::Promise
Rotate certificates of a managed cluster.
Rotate certificates of a managed cluster.
to the HTTP request.
1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1828 def begin_rotate_cluster_certificates_async(resource_group_name, resource_name, custom_headers:nil) fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1 fail ArgumentError, 'resource_name is nil' if resource_name.nil? fail ArgumentError, "'resource_name' should satisfy the constraint - 'MaxLength': '63'" if !resource_name.nil? && resource_name.length > 63 fail ArgumentError, "'resource_name' should satisfy the constraint - 'MinLength': '1'" if !resource_name.nil? && resource_name.length < 1 fail ArgumentError, "'resource_name' should satisfy the constraint - 'Pattern': '^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'" if !resource_name.nil? && resource_name.match(Regexp.new('^^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$$')).nil? request_headers = {} request_headers['Content-Type'] = 'application/json; charset=utf-8' # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}/rotateClusterCertificates' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'resourceName' => resource_name}, query_params: {'api-version' => @client.api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:post, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 202 || status_code == 204 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil? result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil? result end promise.execute end |
#begin_rotate_cluster_certificates_with_http_info(resource_group_name, resource_name, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Rotate certificates of a managed cluster.
Rotate certificates of a managed cluster.
will be added to the HTTP request.
1812 1813 1814 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1812 def begin_rotate_cluster_certificates_with_http_info(resource_group_name, resource_name, custom_headers:nil) begin_rotate_cluster_certificates_async(resource_group_name, resource_name, custom_headers:custom_headers).value! end |
#begin_start(resource_group_name, resource_name, custom_headers: nil) ⇒ Object
Start Managed Cluster
Starts a Stopped Managed Cluster
will be added to the HTTP request.
1981 1982 1983 1984 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1981 def begin_start(resource_group_name, resource_name, custom_headers:nil) response = begin_start_async(resource_group_name, resource_name, custom_headers:custom_headers).value! nil end |
#begin_start_async(resource_group_name, resource_name, custom_headers: nil) ⇒ Concurrent::Promise
Start Managed Cluster
Starts a Stopped Managed Cluster
to the HTTP request.
2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026 2027 2028 2029 2030 2031 2032 2033 2034 2035 2036 2037 2038 2039 2040 2041 2042 2043 2044 2045 2046 2047 2048 2049 2050 2051 2052 2053 2054 2055 2056 2057 2058 2059 2060 2061 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 2014 def begin_start_async(resource_group_name, resource_name, custom_headers:nil) fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1 fail ArgumentError, 'resource_name is nil' if resource_name.nil? fail ArgumentError, "'resource_name' should satisfy the constraint - 'MaxLength': '63'" if !resource_name.nil? && resource_name.length > 63 fail ArgumentError, "'resource_name' should satisfy the constraint - 'MinLength': '1'" if !resource_name.nil? && resource_name.length < 1 fail ArgumentError, "'resource_name' should satisfy the constraint - 'Pattern': '^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'" if !resource_name.nil? && resource_name.match(Regexp.new('^^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$$')).nil? request_headers = {} request_headers['Content-Type'] = 'application/json; charset=utf-8' # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}/start' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'resourceName' => resource_name}, query_params: {'api-version' => @client.api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:post, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 202 || status_code == 204 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil? result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil? result end promise.execute end |
#begin_start_with_http_info(resource_group_name, resource_name, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Start Managed Cluster
Starts a Stopped Managed Cluster
will be added to the HTTP request.
1998 1999 2000 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1998 def begin_start_with_http_info(resource_group_name, resource_name, custom_headers:nil) begin_start_async(resource_group_name, resource_name, custom_headers:custom_headers).value! end |
#begin_stop(resource_group_name, resource_name, custom_headers: nil) ⇒ Object
Stop Managed Cluster
Stops a Running Managed Cluster
will be added to the HTTP request.
1888 1889 1890 1891 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1888 def begin_stop(resource_group_name, resource_name, custom_headers:nil) response = begin_stop_async(resource_group_name, resource_name, custom_headers:custom_headers).value! nil end |
#begin_stop_async(resource_group_name, resource_name, custom_headers: nil) ⇒ Concurrent::Promise
Stop Managed Cluster
Stops a Running Managed Cluster
to the HTTP request.
1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 1940 1941 1942 1943 1944 1945 1946 1947 1948 1949 1950 1951 1952 1953 1954 1955 1956 1957 1958 1959 1960 1961 1962 1963 1964 1965 1966 1967 1968 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1921 def begin_stop_async(resource_group_name, resource_name, custom_headers:nil) fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1 fail ArgumentError, 'resource_name is nil' if resource_name.nil? fail ArgumentError, "'resource_name' should satisfy the constraint - 'MaxLength': '63'" if !resource_name.nil? && resource_name.length > 63 fail ArgumentError, "'resource_name' should satisfy the constraint - 'MinLength': '1'" if !resource_name.nil? && resource_name.length < 1 fail ArgumentError, "'resource_name' should satisfy the constraint - 'Pattern': '^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'" if !resource_name.nil? && resource_name.match(Regexp.new('^^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$$')).nil? request_headers = {} request_headers['Content-Type'] = 'application/json; charset=utf-8' # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}/stop' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'resourceName' => resource_name}, query_params: {'api-version' => @client.api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:post, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 202 || status_code == 204 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil? result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil? result end promise.execute end |
#begin_stop_with_http_info(resource_group_name, resource_name, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Stop Managed Cluster
Stops a Running Managed Cluster
will be added to the HTTP request.
1905 1906 1907 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1905 def begin_stop_with_http_info(resource_group_name, resource_name, custom_headers:nil) begin_stop_async(resource_group_name, resource_name, custom_headers:custom_headers).value! end |
#begin_update_tags(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ ManagedCluster
Updates tags on a managed cluster.
Updates a managed cluster with the specified tags.
Cluster Tags operation. will be added to the HTTP request.
1373 1374 1375 1376 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1373 def (resource_group_name, resource_name, parameters, custom_headers:nil) response = (resource_group_name, resource_name, parameters, custom_headers:custom_headers).value! response.body unless response.nil? end |
#begin_update_tags_async(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ Concurrent::Promise
Updates tags on a managed cluster.
Updates a managed cluster with the specified tags.
Cluster Tags operation. to the HTTP request.
1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1410 def (resource_group_name, resource_name, parameters, custom_headers:nil) fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1 fail ArgumentError, 'resource_name is nil' if resource_name.nil? fail ArgumentError, "'resource_name' should satisfy the constraint - 'MaxLength': '63'" if !resource_name.nil? && resource_name.length > 63 fail ArgumentError, "'resource_name' should satisfy the constraint - 'MinLength': '1'" if !resource_name.nil? && resource_name.length < 1 fail ArgumentError, "'resource_name' should satisfy the constraint - 'Pattern': '^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'" if !resource_name.nil? && resource_name.match(Regexp.new('^^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$$')).nil? fail ArgumentError, 'parameters is nil' if parameters.nil? request_headers = {} request_headers['Content-Type'] = 'application/json; charset=utf-8' # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? # Serialize Request request_mapper = Azure::ContainerService::Mgmt::V2020_12_01::Models::TagsObject.mapper() request_content = @client.serialize(request_mapper, parameters) request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'resourceName' => resource_name}, query_params: {'api-version' => @client.api_version}, body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:patch, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil? result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil? # Deserialize Response if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) result_mapper = Azure::ContainerService::Mgmt::V2020_12_01::Models::ManagedCluster.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e., e.backtrace, result) end end result end promise.execute end |
#begin_update_tags_with_http_info(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Updates tags on a managed cluster.
Updates a managed cluster with the specified tags.
Cluster Tags operation. will be added to the HTTP request.
1392 1393 1394 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1392 def (resource_group_name, resource_name, parameters, custom_headers:nil) (resource_group_name, resource_name, parameters, custom_headers:custom_headers).value! end |
#create_or_update(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ ManagedCluster
Creates or updates a managed cluster.
Creates or updates a managed cluster with the specified configuration for agents and Kubernetes version.
Update a Managed Cluster operation. will be added to the HTTP request.
898 899 900 901 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 898 def create_or_update(resource_group_name, resource_name, parameters, custom_headers:nil) response = create_or_update_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers).value! response.body unless response.nil? end |
#create_or_update_async(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ Concurrent::Promise
Update a Managed Cluster operation. will be added to the HTTP request.
response.
914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 914 def create_or_update_async(resource_group_name, resource_name, parameters, custom_headers:nil) # Send request promise = begin_create_or_update_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers) promise = promise.then do |response| # Defining deserialization method. deserialize_method = lambda do |parsed_response| result_mapper = Azure::ContainerService::Mgmt::V2020_12_01::Models::ManagedCluster.mapper() parsed_response = @client.deserialize(result_mapper, parsed_response) end # Waiting for response. @client.get_long_running_operation_result(response, deserialize_method) end promise end |
#delete(resource_group_name, resource_name, custom_headers: nil) ⇒ Object
Deletes a managed cluster.
Deletes the managed cluster with a specified resource group and name.
will be added to the HTTP request.
990 991 992 993 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 990 def delete(resource_group_name, resource_name, custom_headers:nil) response = delete_async(resource_group_name, resource_name, custom_headers:custom_headers).value! nil end |
#delete_async(resource_group_name, resource_name, custom_headers: nil) ⇒ Concurrent::Promise
will be added to the HTTP request.
response.
1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1004 def delete_async(resource_group_name, resource_name, custom_headers:nil) # Send request promise = begin_delete_async(resource_group_name, resource_name, custom_headers:custom_headers) promise = promise.then do |response| # Defining deserialization method. deserialize_method = lambda do |parsed_response| end # Waiting for response. @client.get_long_running_operation_result(response, deserialize_method) end promise end |
#get(resource_group_name, resource_name, custom_headers: nil) ⇒ ManagedCluster
Gets a managed cluster.
Gets the details of the managed cluster with a specified resource group and name.
will be added to the HTTP request.
789 790 791 792 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 789 def get(resource_group_name, resource_name, custom_headers:nil) response = get_async(resource_group_name, resource_name, custom_headers:custom_headers).value! response.body unless response.nil? end |
#get_access_profile(resource_group_name, resource_name, role_name, custom_headers: nil) ⇒ ManagedClusterAccessProfile
Gets an access profile of a managed cluster.
Gets the accessProfile for the specified role name of the managed cluster with a specified resource group and name. WARNING: This API will be deprecated. Instead use [ListClusterUserCredentials](docs.microsoft.com/en-us/rest/api/aks/managedclusters/listclusterusercredentials) or [ListClusterAdminCredentials](docs.microsoft.com/en-us/rest/api/aks/managedclusters/listclusteradmincredentials) .
accessProfile resource. will be added to the HTTP request.
346 347 348 349 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 346 def get_access_profile(resource_group_name, resource_name, role_name, custom_headers:nil) response = get_access_profile_async(resource_group_name, resource_name, role_name, custom_headers:custom_headers).value! response.body unless response.nil? end |
#get_access_profile_async(resource_group_name, resource_name, role_name, custom_headers: nil) ⇒ Concurrent::Promise
Gets an access profile of a managed cluster.
Gets the accessProfile for the specified role name of the managed cluster with a specified resource group and name. WARNING: This API will be deprecated. Instead use [ListClusterUserCredentials](docs.microsoft.com/en-us/rest/api/aks/managedclusters/listclusterusercredentials) or [ListClusterAdminCredentials](docs.microsoft.com/en-us/rest/api/aks/managedclusters/listclusteradmincredentials) .
accessProfile resource. to the HTTP request.
395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 395 def get_access_profile_async(resource_group_name, resource_name, role_name, custom_headers:nil) fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1 fail ArgumentError, 'resource_name is nil' if resource_name.nil? fail ArgumentError, "'resource_name' should satisfy the constraint - 'MaxLength': '63'" if !resource_name.nil? && resource_name.length > 63 fail ArgumentError, "'resource_name' should satisfy the constraint - 'MinLength': '1'" if !resource_name.nil? && resource_name.length < 1 fail ArgumentError, "'resource_name' should satisfy the constraint - 'Pattern': '^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'" if !resource_name.nil? && resource_name.match(Regexp.new('^^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$$')).nil? fail ArgumentError, 'role_name is nil' if role_name.nil? request_headers = {} request_headers['Content-Type'] = 'application/json; charset=utf-8' # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}/accessProfiles/{roleName}/listCredential' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'resourceName' => resource_name,'roleName' => role_name}, query_params: {'api-version' => @client.api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:post, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil? result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil? # Deserialize Response if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) result_mapper = Azure::ContainerService::Mgmt::V2020_12_01::Models::ManagedClusterAccessProfile.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e., e.backtrace, result) end end result end promise.execute end |
#get_access_profile_with_http_info(resource_group_name, resource_name, role_name, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Gets an access profile of a managed cluster.
Gets the accessProfile for the specified role name of the managed cluster with a specified resource group and name. WARNING: This API will be deprecated. Instead use [ListClusterUserCredentials](docs.microsoft.com/en-us/rest/api/aks/managedclusters/listclusterusercredentials) or [ListClusterAdminCredentials](docs.microsoft.com/en-us/rest/api/aks/managedclusters/listclusteradmincredentials) .
accessProfile resource. will be added to the HTTP request.
371 372 373 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 371 def get_access_profile_with_http_info(resource_group_name, resource_name, role_name, custom_headers:nil) get_access_profile_async(resource_group_name, resource_name, role_name, custom_headers:custom_headers).value! end |
#get_async(resource_group_name, resource_name, custom_headers: nil) ⇒ Concurrent::Promise
Gets a managed cluster.
Gets the details of the managed cluster with a specified resource group and name.
to the HTTP request.
824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 824 def get_async(resource_group_name, resource_name, custom_headers:nil) fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1 fail ArgumentError, 'resource_name is nil' if resource_name.nil? fail ArgumentError, "'resource_name' should satisfy the constraint - 'MaxLength': '63'" if !resource_name.nil? && resource_name.length > 63 fail ArgumentError, "'resource_name' should satisfy the constraint - 'MinLength': '1'" if !resource_name.nil? && resource_name.length < 1 fail ArgumentError, "'resource_name' should satisfy the constraint - 'Pattern': '^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'" if !resource_name.nil? && resource_name.match(Regexp.new('^^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$$')).nil? request_headers = {} request_headers['Content-Type'] = 'application/json; charset=utf-8' # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'resourceName' => resource_name}, query_params: {'api-version' => @client.api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:get, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil? result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil? # Deserialize Response if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) result_mapper = Azure::ContainerService::Mgmt::V2020_12_01::Models::ManagedCluster.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e., e.backtrace, result) end end result end promise.execute end |
#get_upgrade_profile(resource_group_name, resource_name, custom_headers: nil) ⇒ ManagedClusterUpgradeProfile
Gets upgrade profile for a managed cluster.
Gets the details of the upgrade profile for a managed cluster with a specified resource group and name.
will be added to the HTTP request.
232 233 234 235 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 232 def get_upgrade_profile(resource_group_name, resource_name, custom_headers:nil) response = get_upgrade_profile_async(resource_group_name, resource_name, custom_headers:custom_headers).value! response.body unless response.nil? end |
#get_upgrade_profile_async(resource_group_name, resource_name, custom_headers: nil) ⇒ Concurrent::Promise
Gets upgrade profile for a managed cluster.
Gets the details of the upgrade profile for a managed cluster with a specified resource group and name.
to the HTTP request.
267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 267 def get_upgrade_profile_async(resource_group_name, resource_name, custom_headers:nil) fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1 fail ArgumentError, 'resource_name is nil' if resource_name.nil? fail ArgumentError, "'resource_name' should satisfy the constraint - 'MaxLength': '63'" if !resource_name.nil? && resource_name.length > 63 fail ArgumentError, "'resource_name' should satisfy the constraint - 'MinLength': '1'" if !resource_name.nil? && resource_name.length < 1 fail ArgumentError, "'resource_name' should satisfy the constraint - 'Pattern': '^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'" if !resource_name.nil? && resource_name.match(Regexp.new('^^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$$')).nil? request_headers = {} request_headers['Content-Type'] = 'application/json; charset=utf-8' # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}/upgradeProfiles/default' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'resourceName' => resource_name}, query_params: {'api-version' => @client.api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:get, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil? result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil? # Deserialize Response if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) result_mapper = Azure::ContainerService::Mgmt::V2020_12_01::Models::ManagedClusterUpgradeProfile.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e., e.backtrace, result) end end result end promise.execute end |
#get_upgrade_profile_with_http_info(resource_group_name, resource_name, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Gets upgrade profile for a managed cluster.
Gets the details of the upgrade profile for a managed cluster with a specified resource group and name.
will be added to the HTTP request.
250 251 252 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 250 def get_upgrade_profile_with_http_info(resource_group_name, resource_name, custom_headers:nil) get_upgrade_profile_async(resource_group_name, resource_name, custom_headers:custom_headers).value! end |
#get_with_http_info(resource_group_name, resource_name, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Gets a managed cluster.
Gets the details of the managed cluster with a specified resource group and name.
will be added to the HTTP request.
807 808 809 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 807 def get_with_http_info(resource_group_name, resource_name, custom_headers:nil) get_async(resource_group_name, resource_name, custom_headers:custom_headers).value! end |
#list(custom_headers: nil) ⇒ Array<ManagedCluster>
Gets a list of managed clusters in the specified subscription.
Gets a list of managed clusters in the specified subscription. The operation returns properties of each managed cluster.
will be added to the HTTP request.
35 36 37 38 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 35 def list(custom_headers:nil) first_page = list_as_lazy(custom_headers:custom_headers) first_page.get_all_items end |
#list_as_lazy(custom_headers: nil) ⇒ ManagedClusterListResult
Gets a list of managed clusters in the specified subscription.
Gets a list of managed clusters in the specified subscription. The operation returns properties of each managed cluster.
will be added to the HTTP request.
response.
2273 2274 2275 2276 2277 2278 2279 2280 2281 2282 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 2273 def list_as_lazy(custom_headers:nil) response = list_async(custom_headers:custom_headers).value! unless response.nil? page = response.body page.next_method = Proc.new do |next_page_link| list_next_async(next_page_link, custom_headers:custom_headers) end page end end |
#list_async(custom_headers: nil) ⇒ Concurrent::Promise
Gets a list of managed clusters in the specified subscription.
Gets a list of managed clusters in the specified subscription. The operation returns properties of each managed cluster.
to the HTTP request.
66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 66 def list_async(custom_headers:nil) fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? request_headers = {} request_headers['Content-Type'] = 'application/json; charset=utf-8' # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? path_template = 'subscriptions/{subscriptionId}/providers/Microsoft.ContainerService/managedClusters' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => @client.api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:get, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil? result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil? # Deserialize Response if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) result_mapper = Azure::ContainerService::Mgmt::V2020_12_01::Models::ManagedClusterListResult.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e., e.backtrace, result) end end result end promise.execute end |
#list_by_resource_group(resource_group_name, custom_headers: nil) ⇒ Array<ManagedCluster>
Lists managed clusters in the specified subscription and resource group.
Lists managed clusters in the specified subscription and resource group. The operation returns properties of each managed cluster.
will be added to the HTTP request.
131 132 133 134 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 131 def list_by_resource_group(resource_group_name, custom_headers:nil) first_page = list_by_resource_group_as_lazy(resource_group_name, custom_headers:custom_headers) first_page.get_all_items end |
#list_by_resource_group_as_lazy(resource_group_name, custom_headers: nil) ⇒ ManagedClusterListResult
Lists managed clusters in the specified subscription and resource group.
Lists managed clusters in the specified subscription and resource group. The operation returns properties of each managed cluster.
will be added to the HTTP request.
response.
2297 2298 2299 2300 2301 2302 2303 2304 2305 2306 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 2297 def list_by_resource_group_as_lazy(resource_group_name, custom_headers:nil) response = list_by_resource_group_async(resource_group_name, custom_headers:custom_headers).value! unless response.nil? page = response.body page.next_method = Proc.new do |next_page_link| list_by_resource_group_next_async(next_page_link, custom_headers:custom_headers) end page end end |
#list_by_resource_group_async(resource_group_name, custom_headers: nil) ⇒ Concurrent::Promise
Lists managed clusters in the specified subscription and resource group.
Lists managed clusters in the specified subscription and resource group. The operation returns properties of each managed cluster.
to the HTTP request.
164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 164 def list_by_resource_group_async(resource_group_name, custom_headers:nil) fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1 request_headers = {} request_headers['Content-Type'] = 'application/json; charset=utf-8' # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name}, query_params: {'api-version' => @client.api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:get, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil? result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil? # Deserialize Response if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) result_mapper = Azure::ContainerService::Mgmt::V2020_12_01::Models::ManagedClusterListResult.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e., e.backtrace, result) end end result end promise.execute end |
#list_by_resource_group_next(next_page_link, custom_headers: nil) ⇒ ManagedClusterListResult
Lists managed clusters in the specified subscription and resource group.
Lists managed clusters in the specified subscription and resource group. The operation returns properties of each managed cluster.
to List operation. will be added to the HTTP request.
2175 2176 2177 2178 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 2175 def list_by_resource_group_next(next_page_link, custom_headers:nil) response = list_by_resource_group_next_async(next_page_link, custom_headers:custom_headers).value! response.body unless response.nil? end |
#list_by_resource_group_next_async(next_page_link, custom_headers: nil) ⇒ Concurrent::Promise
Lists managed clusters in the specified subscription and resource group.
Lists managed clusters in the specified subscription and resource group. The operation returns properties of each managed cluster.
to List operation. to the HTTP request.
2210 2211 2212 2213 2214 2215 2216 2217 2218 2219 2220 2221 2222 2223 2224 2225 2226 2227 2228 2229 2230 2231 2232 2233 2234 2235 2236 2237 2238 2239 2240 2241 2242 2243 2244 2245 2246 2247 2248 2249 2250 2251 2252 2253 2254 2255 2256 2257 2258 2259 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 2210 def list_by_resource_group_next_async(next_page_link, custom_headers:nil) fail ArgumentError, 'next_page_link is nil' if next_page_link.nil? request_headers = {} request_headers['Content-Type'] = 'application/json; charset=utf-8' # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? path_template = '{nextLink}' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], skip_encoding_path_params: {'nextLink' => next_page_link}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:get, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil? result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil? # Deserialize Response if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) result_mapper = Azure::ContainerService::Mgmt::V2020_12_01::Models::ManagedClusterListResult.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e., e.backtrace, result) end end result end promise.execute end |
#list_by_resource_group_next_with_http_info(next_page_link, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Lists managed clusters in the specified subscription and resource group.
Lists managed clusters in the specified subscription and resource group. The operation returns properties of each managed cluster.
to List operation. will be added to the HTTP request.
2193 2194 2195 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 2193 def list_by_resource_group_next_with_http_info(next_page_link, custom_headers:nil) list_by_resource_group_next_async(next_page_link, custom_headers:custom_headers).value! end |
#list_by_resource_group_with_http_info(resource_group_name, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Lists managed clusters in the specified subscription and resource group.
Lists managed clusters in the specified subscription and resource group. The operation returns properties of each managed cluster.
will be added to the HTTP request.
148 149 150 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 148 def list_by_resource_group_with_http_info(resource_group_name, custom_headers:nil) list_by_resource_group_async(resource_group_name, custom_headers:custom_headers).value! end |
#list_cluster_admin_credentials(resource_group_name, resource_name, custom_headers: nil) ⇒ CredentialResults
Gets cluster admin credential of a managed cluster.
Gets cluster admin credential of the managed cluster with a specified resource group and name.
will be added to the HTTP request.
468 469 470 471 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 468 def list_cluster_admin_credentials(resource_group_name, resource_name, custom_headers:nil) response = list_cluster_admin_credentials_async(resource_group_name, resource_name, custom_headers:custom_headers).value! response.body unless response.nil? end |
#list_cluster_admin_credentials_async(resource_group_name, resource_name, custom_headers: nil) ⇒ Concurrent::Promise
Gets cluster admin credential of a managed cluster.
Gets cluster admin credential of the managed cluster with a specified resource group and name.
to the HTTP request.
503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 503 def list_cluster_admin_credentials_async(resource_group_name, resource_name, custom_headers:nil) fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1 fail ArgumentError, 'resource_name is nil' if resource_name.nil? fail ArgumentError, "'resource_name' should satisfy the constraint - 'MaxLength': '63'" if !resource_name.nil? && resource_name.length > 63 fail ArgumentError, "'resource_name' should satisfy the constraint - 'MinLength': '1'" if !resource_name.nil? && resource_name.length < 1 fail ArgumentError, "'resource_name' should satisfy the constraint - 'Pattern': '^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'" if !resource_name.nil? && resource_name.match(Regexp.new('^^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$$')).nil? request_headers = {} request_headers['Content-Type'] = 'application/json; charset=utf-8' # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}/listClusterAdminCredential' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'resourceName' => resource_name}, query_params: {'api-version' => @client.api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:post, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil? result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil? # Deserialize Response if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) result_mapper = Azure::ContainerService::Mgmt::V2020_12_01::Models::CredentialResults.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e., e.backtrace, result) end end result end promise.execute end |
#list_cluster_admin_credentials_with_http_info(resource_group_name, resource_name, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Gets cluster admin credential of a managed cluster.
Gets cluster admin credential of the managed cluster with a specified resource group and name.
will be added to the HTTP request.
486 487 488 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 486 def list_cluster_admin_credentials_with_http_info(resource_group_name, resource_name, custom_headers:nil) list_cluster_admin_credentials_async(resource_group_name, resource_name, custom_headers:custom_headers).value! end |
#list_cluster_monitoring_user_credentials(resource_group_name, resource_name, custom_headers: nil) ⇒ CredentialResults
Gets cluster monitoring user credential of a managed cluster.
Gets cluster monitoring user credential of the managed cluster with a specified resource group and name.
will be added to the HTTP request.
682 683 684 685 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 682 def list_cluster_monitoring_user_credentials(resource_group_name, resource_name, custom_headers:nil) response = list_cluster_monitoring_user_credentials_async(resource_group_name, resource_name, custom_headers:custom_headers).value! response.body unless response.nil? end |
#list_cluster_monitoring_user_credentials_async(resource_group_name, resource_name, custom_headers: nil) ⇒ Concurrent::Promise
Gets cluster monitoring user credential of a managed cluster.
Gets cluster monitoring user credential of the managed cluster with a specified resource group and name.
to the HTTP request.
717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 717 def list_cluster_monitoring_user_credentials_async(resource_group_name, resource_name, custom_headers:nil) fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1 fail ArgumentError, 'resource_name is nil' if resource_name.nil? fail ArgumentError, "'resource_name' should satisfy the constraint - 'MaxLength': '63'" if !resource_name.nil? && resource_name.length > 63 fail ArgumentError, "'resource_name' should satisfy the constraint - 'MinLength': '1'" if !resource_name.nil? && resource_name.length < 1 fail ArgumentError, "'resource_name' should satisfy the constraint - 'Pattern': '^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'" if !resource_name.nil? && resource_name.match(Regexp.new('^^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$$')).nil? request_headers = {} request_headers['Content-Type'] = 'application/json; charset=utf-8' # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}/listClusterMonitoringUserCredential' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'resourceName' => resource_name}, query_params: {'api-version' => @client.api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:post, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil? result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil? # Deserialize Response if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) result_mapper = Azure::ContainerService::Mgmt::V2020_12_01::Models::CredentialResults.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e., e.backtrace, result) end end result end promise.execute end |
#list_cluster_monitoring_user_credentials_with_http_info(resource_group_name, resource_name, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Gets cluster monitoring user credential of a managed cluster.
Gets cluster monitoring user credential of the managed cluster with a specified resource group and name.
will be added to the HTTP request.
700 701 702 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 700 def list_cluster_monitoring_user_credentials_with_http_info(resource_group_name, resource_name, custom_headers:nil) list_cluster_monitoring_user_credentials_async(resource_group_name, resource_name, custom_headers:custom_headers).value! end |
#list_cluster_user_credentials(resource_group_name, resource_name, custom_headers: nil) ⇒ CredentialResults
Gets cluster user credential of a managed cluster.
Gets cluster user credential of the managed cluster with a specified resource group and name.
will be added to the HTTP request.
575 576 577 578 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 575 def list_cluster_user_credentials(resource_group_name, resource_name, custom_headers:nil) response = list_cluster_user_credentials_async(resource_group_name, resource_name, custom_headers:custom_headers).value! response.body unless response.nil? end |
#list_cluster_user_credentials_async(resource_group_name, resource_name, custom_headers: nil) ⇒ Concurrent::Promise
Gets cluster user credential of a managed cluster.
Gets cluster user credential of the managed cluster with a specified resource group and name.
to the HTTP request.
610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 610 def list_cluster_user_credentials_async(resource_group_name, resource_name, custom_headers:nil) fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1 fail ArgumentError, 'resource_name is nil' if resource_name.nil? fail ArgumentError, "'resource_name' should satisfy the constraint - 'MaxLength': '63'" if !resource_name.nil? && resource_name.length > 63 fail ArgumentError, "'resource_name' should satisfy the constraint - 'MinLength': '1'" if !resource_name.nil? && resource_name.length < 1 fail ArgumentError, "'resource_name' should satisfy the constraint - 'Pattern': '^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$'" if !resource_name.nil? && resource_name.match(Regexp.new('^^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$$')).nil? request_headers = {} request_headers['Content-Type'] = 'application/json; charset=utf-8' # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}/listClusterUserCredential' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'resourceName' => resource_name}, query_params: {'api-version' => @client.api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:post, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil? result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil? # Deserialize Response if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) result_mapper = Azure::ContainerService::Mgmt::V2020_12_01::Models::CredentialResults.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e., e.backtrace, result) end end result end promise.execute end |
#list_cluster_user_credentials_with_http_info(resource_group_name, resource_name, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Gets cluster user credential of a managed cluster.
Gets cluster user credential of the managed cluster with a specified resource group and name.
will be added to the HTTP request.
593 594 595 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 593 def list_cluster_user_credentials_with_http_info(resource_group_name, resource_name, custom_headers:nil) list_cluster_user_credentials_async(resource_group_name, resource_name, custom_headers:custom_headers).value! end |
#list_next(next_page_link, custom_headers: nil) ⇒ ManagedClusterListResult
Gets a list of managed clusters in the specified subscription.
Gets a list of managed clusters in the specified subscription. The operation returns properties of each managed cluster.
to List operation. will be added to the HTTP request.
2076 2077 2078 2079 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 2076 def list_next(next_page_link, custom_headers:nil) response = list_next_async(next_page_link, custom_headers:custom_headers).value! response.body unless response.nil? end |
#list_next_async(next_page_link, custom_headers: nil) ⇒ Concurrent::Promise
Gets a list of managed clusters in the specified subscription.
Gets a list of managed clusters in the specified subscription. The operation returns properties of each managed cluster.
to List operation. to the HTTP request.
2111 2112 2113 2114 2115 2116 2117 2118 2119 2120 2121 2122 2123 2124 2125 2126 2127 2128 2129 2130 2131 2132 2133 2134 2135 2136 2137 2138 2139 2140 2141 2142 2143 2144 2145 2146 2147 2148 2149 2150 2151 2152 2153 2154 2155 2156 2157 2158 2159 2160 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 2111 def list_next_async(next_page_link, custom_headers:nil) fail ArgumentError, 'next_page_link is nil' if next_page_link.nil? request_headers = {} request_headers['Content-Type'] = 'application/json; charset=utf-8' # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? path_template = '{nextLink}' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], skip_encoding_path_params: {'nextLink' => next_page_link}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:get, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil? result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil? # Deserialize Response if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) result_mapper = Azure::ContainerService::Mgmt::V2020_12_01::Models::ManagedClusterListResult.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e., e.backtrace, result) end end result end promise.execute end |
#list_next_with_http_info(next_page_link, custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Gets a list of managed clusters in the specified subscription.
Gets a list of managed clusters in the specified subscription. The operation returns properties of each managed cluster.
to List operation. will be added to the HTTP request.
2094 2095 2096 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 2094 def list_next_with_http_info(next_page_link, custom_headers:nil) list_next_async(next_page_link, custom_headers:custom_headers).value! end |
#list_with_http_info(custom_headers: nil) ⇒ MsRestAzure::AzureOperationResponse
Gets a list of managed clusters in the specified subscription.
Gets a list of managed clusters in the specified subscription. The operation returns properties of each managed cluster.
will be added to the HTTP request.
51 52 53 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 51 def list_with_http_info(custom_headers:nil) list_async(custom_headers:custom_headers).value! end |
#reset_aadprofile(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ Object
Reset AAD Profile of a managed cluster.
Update the AAD Profile for a managed cluster.
AAD Profile operation for a Managed Cluster. will be added to the HTTP request.
1076 1077 1078 1079 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1076 def reset_aadprofile(resource_group_name, resource_name, parameters, custom_headers:nil) response = reset_aadprofile_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers).value! nil end |
#reset_aadprofile_async(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ Concurrent::Promise
AAD Profile operation for a Managed Cluster. will be added to the HTTP request.
response.
1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1092 def reset_aadprofile_async(resource_group_name, resource_name, parameters, custom_headers:nil) # Send request promise = begin_reset_aadprofile_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers) promise = promise.then do |response| # Defining deserialization method. deserialize_method = lambda do |parsed_response| end # Waiting for response. @client.get_long_running_operation_result(response, deserialize_method) end promise end |
#reset_service_principal_profile(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ Object
Reset Service Principal Profile of a managed cluster.
Update the service principal Profile for a managed cluster.
to the Reset Service Principal Profile operation for a Managed Cluster. will be added to the HTTP request.
1032 1033 1034 1035 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1032 def reset_service_principal_profile(resource_group_name, resource_name, parameters, custom_headers:nil) response = reset_service_principal_profile_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers).value! nil end |
#reset_service_principal_profile_async(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ Concurrent::Promise
to the Reset Service Principal Profile operation for a Managed Cluster. will be added to the HTTP request.
response.
1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1048 def reset_service_principal_profile_async(resource_group_name, resource_name, parameters, custom_headers:nil) # Send request promise = begin_reset_service_principal_profile_async(resource_group_name, resource_name, parameters, custom_headers:custom_headers) promise = promise.then do |response| # Defining deserialization method. deserialize_method = lambda do |parsed_response| end # Waiting for response. @client.get_long_running_operation_result(response, deserialize_method) end promise end |
#rotate_cluster_certificates(resource_group_name, resource_name, custom_headers: nil) ⇒ Object
Rotate certificates of a managed cluster.
Rotate certificates of a managed cluster.
will be added to the HTTP request.
1118 1119 1120 1121 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1118 def rotate_cluster_certificates(resource_group_name, resource_name, custom_headers:nil) response = rotate_cluster_certificates_async(resource_group_name, resource_name, custom_headers:custom_headers).value! nil end |
#rotate_cluster_certificates_async(resource_group_name, resource_name, custom_headers: nil) ⇒ Concurrent::Promise
will be added to the HTTP request.
response.
1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1132 def rotate_cluster_certificates_async(resource_group_name, resource_name, custom_headers:nil) # Send request promise = begin_rotate_cluster_certificates_async(resource_group_name, resource_name, custom_headers:custom_headers) promise = promise.then do |response| # Defining deserialization method. deserialize_method = lambda do |parsed_response| end # Waiting for response. @client.get_long_running_operation_result(response, deserialize_method) end promise end |
#start(resource_group_name, resource_name, custom_headers: nil) ⇒ Object
Start Managed Cluster
Starts a Stopped Managed Cluster
will be added to the HTTP request.
1198 1199 1200 1201 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1198 def start(resource_group_name, resource_name, custom_headers:nil) response = start_async(resource_group_name, resource_name, custom_headers:custom_headers).value! nil end |
#start_async(resource_group_name, resource_name, custom_headers: nil) ⇒ Concurrent::Promise
will be added to the HTTP request.
response.
1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1212 def start_async(resource_group_name, resource_name, custom_headers:nil) # Send request promise = begin_start_async(resource_group_name, resource_name, custom_headers:custom_headers) promise = promise.then do |response| # Defining deserialization method. deserialize_method = lambda do |parsed_response| end # Waiting for response. @client.get_long_running_operation_result(response, deserialize_method) end promise end |
#stop(resource_group_name, resource_name, custom_headers: nil) ⇒ Object
Stop Managed Cluster
Stops a Running Managed Cluster
will be added to the HTTP request.
1158 1159 1160 1161 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1158 def stop(resource_group_name, resource_name, custom_headers:nil) response = stop_async(resource_group_name, resource_name, custom_headers:custom_headers).value! nil end |
#stop_async(resource_group_name, resource_name, custom_headers: nil) ⇒ Concurrent::Promise
will be added to the HTTP request.
response.
1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 1172 def stop_async(resource_group_name, resource_name, custom_headers:nil) # Send request promise = begin_stop_async(resource_group_name, resource_name, custom_headers:custom_headers) promise = promise.then do |response| # Defining deserialization method. deserialize_method = lambda do |parsed_response| end # Waiting for response. @client.get_long_running_operation_result(response, deserialize_method) end promise end |
#update_tags(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ ManagedCluster
Updates tags on a managed cluster.
Updates a managed cluster with the specified tags.
Cluster Tags operation. will be added to the HTTP request.
946 947 948 949 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 946 def (resource_group_name, resource_name, parameters, custom_headers:nil) response = (resource_group_name, resource_name, parameters, custom_headers:custom_headers).value! response.body unless response.nil? end |
#update_tags_async(resource_group_name, resource_name, parameters, custom_headers: nil) ⇒ Concurrent::Promise
Cluster Tags operation. will be added to the HTTP request.
response.
962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 |
# File 'lib/2020-12-01/generated/azure_mgmt_container_service/managed_clusters.rb', line 962 def (resource_group_name, resource_name, parameters, custom_headers:nil) # Send request promise = (resource_group_name, resource_name, parameters, custom_headers:custom_headers) promise = promise.then do |response| # Defining deserialization method. deserialize_method = lambda do |parsed_response| result_mapper = Azure::ContainerService::Mgmt::V2020_12_01::Models::ManagedCluster.mapper() parsed_response = @client.deserialize(result_mapper, parsed_response) end # Waiting for response. @client.get_long_running_operation_result(response, deserialize_method) end promise end |