From 29bd339dfd2bfda2139487f134cba9479fe9f7b6 Mon Sep 17 00:00:00 2001 From: SDKAuto Date: Mon, 22 Mar 2021 23:21:24 +0000 Subject: [PATCH] CodeGen from PR 13557 in Azure/azure-rest-api-specs Merge e339b9b3480b43ccabb2f6d11bce2ea6d10e5d38 into 55bed130033df2586a5f0be431f2313611f258d8 --- .../src/containerServiceClientContext.ts | 2 +- .../src/models/agentPoolsMappers.ts | 2 + .../arm-containerservice/src/models/index.ts | 306 ++++++++++++++-- .../maintenanceConfigurationsMappers.ts | 2 + .../src/models/managedClustersMappers.ts | 4 + .../src/models/mappers.ts | 335 +++++++++++++++--- .../src/models/parameters.ts | 10 + .../privateEndpointConnectionsMappers.ts | 2 + .../src/operations/managedClusters.ts | 134 +++++++ 9 files changed, 706 insertions(+), 91 deletions(-) diff --git a/sdk/containerservice/arm-containerservice/src/containerServiceClientContext.ts b/sdk/containerservice/arm-containerservice/src/containerServiceClientContext.ts index c4696f992968..2f859f9dce91 100644 --- a/sdk/containerservice/arm-containerservice/src/containerServiceClientContext.ts +++ b/sdk/containerservice/arm-containerservice/src/containerServiceClientContext.ts @@ -44,7 +44,7 @@ export class ContainerServiceClientContext extends msRestAzure.AzureServiceClien super(credentials, options); - this.apiVersion = '2020-12-01'; + this.apiVersion = '2021-03-01'; this.acceptLanguage = 'en-US'; this.longRunningOperationRetryTimeout = 30; this.baseUri = options.baseUri || this.baseUri || "https://management.azure.com"; diff --git a/sdk/containerservice/arm-containerservice/src/models/agentPoolsMappers.ts b/sdk/containerservice/arm-containerservice/src/models/agentPoolsMappers.ts index 6c85a191b95f..22e6726ce610 100644 --- a/sdk/containerservice/arm-containerservice/src/models/agentPoolsMappers.ts +++ b/sdk/containerservice/arm-containerservice/src/models/agentPoolsMappers.ts @@ -32,6 +32,7 @@ export { ManagedClusterAgentPoolProfileProperties, ManagedClusterAPIServerAccessProfile, ManagedClusterAutoUpgradeProfile, + ManagedClusterHTTPProxyConfig, ManagedClusterIdentity, ManagedClusterIdentityUserAssignedIdentitiesValue, ManagedClusterLoadBalancerProfile, @@ -50,6 +51,7 @@ export { PowerState, PrivateEndpoint, PrivateEndpointConnection, + PrivateLinkResource, PrivateLinkServiceConnectionState, Resource, ResourceReference, diff --git a/sdk/containerservice/arm-containerservice/src/models/index.ts b/sdk/containerservice/arm-containerservice/src/models/index.ts index 5cbe991194d2..016a071ee462 100644 --- a/sdk/containerservice/arm-containerservice/src/models/index.ts +++ b/sdk/containerservice/arm-containerservice/src/models/index.ts @@ -482,7 +482,7 @@ export interface ManagedClusterAgentPoolProfileProperties { /** * KubeletDiskType determines the placement of emptyDir volumes, container runtime data root, and * Kubelet ephemeral storage. Currently allows one value, OS, resulting in Kubelet using the OS - * disk for data. Possible values include: 'OS' + * disk for data. Possible values include: 'OS', 'Temporary' */ kubeletDiskType?: KubeletDiskType; /** @@ -502,6 +502,11 @@ export interface ManagedClusterAgentPoolProfileProperties { * Possible values include: 'Linux', 'Windows'. Default value: 'Linux'. */ osType?: OSType; + /** + * OsSKU to be used to specify os sku. Choose from Ubuntu(default) and CBLMariner for Linux + * OSType. Not applicable to Windows OSType. Possible values include: 'Ubuntu', 'CBLMariner' + */ + osSKU?: OSSKU; /** * Maximum number of nodes for auto-scaling */ @@ -554,6 +559,10 @@ export interface ManagedClusterAgentPoolProfileProperties { * Enable public IP for nodes */ enableNodePublicIP?: boolean; + /** + * Public IP Prefix ID. VM nodes use IPs assigned from this Public IP Prefix. + */ + nodePublicIPPrefixID?: string; /** * ScaleSetPriority to be used to specify virtual machine scale set priority. Default to regular. * Possible values include: 'Spot', 'Regular'. Default value: 'Regular'. @@ -600,6 +609,16 @@ export interface ManagedClusterAgentPoolProfileProperties { * Whether to enable EncryptionAtHost */ enableEncryptionAtHost?: boolean; + /** + * Whether to use FIPS enabled OS + */ + enableFIPS?: boolean; + /** + * GPUInstanceProfile to be used to specify GPU MIG instance profile for supported GPU VM SKU. + * Supported values are MIG1g, MIG2g, MIG3g, MIG4g and MIG7g. Possible values include: 'MIG1g', + * 'MIG2g', 'MIG3g', 'MIG4g', 'MIG7g' + */ + gpuInstanceProfile?: GPUInstanceProfile; } /** @@ -678,7 +697,7 @@ export interface AgentPool extends SubResource { /** * KubeletDiskType determines the placement of emptyDir volumes, container runtime data root, and * Kubelet ephemeral storage. Currently allows one value, OS, resulting in Kubelet using the OS - * disk for data. Possible values include: 'OS' + * disk for data. Possible values include: 'OS', 'Temporary' */ kubeletDiskType?: KubeletDiskType; /** @@ -698,6 +717,11 @@ export interface AgentPool extends SubResource { * Possible values include: 'Linux', 'Windows'. Default value: 'Linux'. */ osType?: OSType; + /** + * OsSKU to be used to specify os sku. Choose from Ubuntu(default) and CBLMariner for Linux + * OSType. Not applicable to Windows OSType. Possible values include: 'Ubuntu', 'CBLMariner' + */ + osSKU?: OSSKU; /** * Maximum number of nodes for auto-scaling */ @@ -750,6 +774,10 @@ export interface AgentPool extends SubResource { * Enable public IP for nodes */ enableNodePublicIP?: boolean; + /** + * Public IP Prefix ID. VM nodes use IPs assigned from this Public IP Prefix. + */ + nodePublicIPPrefixID?: string; /** * ScaleSetPriority to be used to specify virtual machine scale set priority. Default to regular. * Possible values include: 'Spot', 'Regular'. Default value: 'Regular'. @@ -796,6 +824,16 @@ export interface AgentPool extends SubResource { * Whether to enable EncryptionAtHost */ enableEncryptionAtHost?: boolean; + /** + * Whether to use FIPS enabled OS + */ + enableFIPS?: boolean; + /** + * GPUInstanceProfile to be used to specify GPU MIG instance profile for supported GPU VM SKU. + * Supported values are MIG1g, MIG2g, MIG3g, MIG4g and MIG7g. Possible values include: 'MIG1g', + * 'MIG2g', 'MIG3g', 'MIG4g', 'MIG7g' + */ + gpuInstanceProfile?: GPUInstanceProfile; } /** @@ -825,6 +863,10 @@ export interface ManagedClusterWindowsProfile { * Benefits for Windows VMs. Possible values include: 'None', 'Windows_Server' */ licenseType?: LicenseType; + /** + * Whether to enable CSI proxy. + */ + enableCSIProxy?: boolean; } /** @@ -1071,6 +1113,65 @@ export interface MaintenanceConfiguration extends SubResource { notAllowedTime?: TimeSpan[]; } +/** + * run command request + */ +export interface RunCommandRequest { + /** + * command to run. + */ + command: string; + /** + * base64 encoded zip file, contains files required by the command + */ + context?: string; + /** + * AuthToken issued for AKS AAD Server App. + */ + clusterToken?: string; +} + +/** + * run command result. + */ +export interface RunCommandResult { + /** + * command id. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly id?: string; + /** + * provisioning State + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly provisioningState?: string; + /** + * exit code of the command + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly exitCode?: number; + /** + * time when the command started. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly startedAt?: Date; + /** + * time when the command finished. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly finishedAt?: Date; + /** + * command output. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly logs?: string; + /** + * explain why provisioningState is set to failed (if so). + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly reason?: string; +} + /** * Profile for diagnostics on the container service VMs. */ @@ -1161,6 +1262,10 @@ export interface ManagedClusterPodIdentity { * Namespace of the pod identity. */ namespace: string; + /** + * Binding selector to use for the AzureIdentityBinding resource. + */ + bindingSelector?: string; /** * Information of the user assigned identity. */ @@ -1203,6 +1308,10 @@ export interface ManagedClusterPodIdentityProfile { * Whether the pod identity addon is enabled. */ enabled?: boolean; + /** + * Customer consent for enabling AAD pod identity addon in cluster using Kubenet network plugin. + */ + allowNetworkPluginKubenet?: boolean; /** * User assigned pod identity settings. */ @@ -1253,7 +1362,8 @@ export interface ManagedClusterAADProfile { */ export interface ManagedClusterAutoUpgradeProfile { /** - * upgrade channel for auto upgrade. Possible values include: 'rapid', 'stable', 'patch', 'none' + * upgrade channel for auto upgrade. Possible values include: 'rapid', 'stable', 'patch', + * 'node-image', 'none' */ upgradeChannel?: UpgradeChannel; } @@ -1308,6 +1418,59 @@ export interface ManagedClusterAPIServerAccessProfile { export interface ManagedClusterPropertiesIdentityProfileValue extends UserAssignedIdentity { } +/** + * A private link resource + */ +export interface PrivateLinkResource { + /** + * The ID of the private link resource. + */ + id?: string; + /** + * The name of the private link resource. + */ + name?: string; + /** + * The resource type. + */ + type?: string; + /** + * The group ID of the resource. + */ + groupId?: string; + /** + * RequiredMembers of the resource + */ + requiredMembers?: string[]; + /** + * The private link service ID of the resource, this field is exposed only to NRP internally. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly privateLinkServiceID?: string; +} + +/** + * Configurations for provisioning the cluster with HTTP proxy servers. + */ +export interface ManagedClusterHTTPProxyConfig { + /** + * HTTP proxy server endpoint to use. + */ + httpProxy?: string; + /** + * HTTPS proxy server endpoint to use. + */ + httpsProxy?: string; + /** + * Endpoints that should not go through proxy. + */ + noProxy?: string[]; + /** + * Alternative CA cert to use for connecting to proxy servers. + */ + trustedCa?: string; +} + /** * An interface representing ManagedClusterIdentityUserAssignedIdentitiesValue. */ @@ -1396,6 +1559,10 @@ export interface ManagedCluster extends Resource { * DNS prefix specified when creating the managed cluster. */ dnsPrefix?: string; + /** + * FQDN subdomain specified when creating private cluster with custom private dns zone. + */ + fqdnSubdomain?: string; /** * FQDN for the master pool. * **NOTE: This property will not be serialized. It can only be populated by the server.** @@ -1406,6 +1573,11 @@ export interface ManagedCluster extends Resource { * **NOTE: This property will not be serialized. It can only be populated by the server.** */ readonly privateFQDN?: string; + /** + * FQDN for the master pool which used by proxy config. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly azurePortalFQDN?: string; /** * Properties of the agent pool. */ @@ -1472,6 +1644,19 @@ export interface ManagedCluster extends Resource { * Identities associated with the cluster. */ identityProfile?: { [propertyName: string]: ManagedClusterPropertiesIdentityProfileValue }; + /** + * Private link resources associated with the cluster. + */ + privateLinkResources?: PrivateLinkResource[]; + /** + * If set to true, getting static credential will be disabled for this cluster. Expected to only + * be used for AAD clusters. + */ + disableLocalAccounts?: boolean; + /** + * Configurations for provisioning the cluster with HTTP proxy servers. + */ + httpProxyConfig?: ManagedClusterHTTPProxyConfig; /** * The identity of the managed cluster, if configured. */ @@ -1751,37 +1936,6 @@ export interface PrivateEndpointConnectionListResult { value?: PrivateEndpointConnection[]; } -/** - * A private link resource - */ -export interface PrivateLinkResource { - /** - * The ID of the private link resource. - */ - id?: string; - /** - * The name of the private link resource. - */ - name?: string; - /** - * The resource type. - */ - type?: string; - /** - * The group ID of the resource. - */ - groupId?: string; - /** - * RequiredMembers of the resource - */ - requiredMembers?: string[]; - /** - * The private link service ID of the resource, this field is exposed only to NRP internally. - * **NOTE: This property will not be serialized. It can only be populated by the server.** - */ - readonly privateLinkServiceID?: string; -} - /** * A list of private link resources */ @@ -1909,11 +2063,11 @@ export type OSDiskType = 'Managed' | 'Ephemeral'; /** * Defines values for KubeletDiskType. - * Possible values include: 'OS' + * Possible values include: 'OS', 'Temporary' * @readonly * @enum {string} */ -export type KubeletDiskType = 'OS'; +export type KubeletDiskType = 'OS' | 'Temporary'; /** * Defines values for OSType. @@ -1923,6 +2077,14 @@ export type KubeletDiskType = 'OS'; */ export type OSType = 'Linux' | 'Windows'; +/** + * Defines values for OSSKU. + * Possible values include: 'Ubuntu', 'CBLMariner' + * @readonly + * @enum {string} + */ +export type OSSKU = 'Ubuntu' | 'CBLMariner'; + /** * Defines values for AgentPoolType. * Possible values include: 'VirtualMachineScaleSets', 'AvailabilitySet' @@ -1963,6 +2125,14 @@ export type ScaleSetPriority = 'Spot' | 'Regular'; */ export type ScaleSetEvictionPolicy = 'Delete' | 'Deallocate'; +/** + * Defines values for GPUInstanceProfile. + * Possible values include: 'MIG1g', 'MIG2g', 'MIG3g', 'MIG4g', 'MIG7g' + * @readonly + * @enum {string} + */ +export type GPUInstanceProfile = 'MIG1g' | 'MIG2g' | 'MIG3g' | 'MIG4g' | 'MIG7g'; + /** * Defines values for LicenseType. * Possible values include: 'None', 'Windows_Server' @@ -2038,11 +2208,11 @@ export type ManagedClusterPodIdentityProvisioningState = 'Assigned' | 'Updating' /** * Defines values for UpgradeChannel. - * Possible values include: 'rapid', 'stable', 'patch', 'none' + * Possible values include: 'rapid', 'stable', 'patch', 'node-image', 'none' * @readonly * @enum {string} */ -export type UpgradeChannel = 'rapid' | 'stable' | 'patch' | 'none'; +export type UpgradeChannel = 'rapid' | 'stable' | 'patch' | 'node-image' | 'none'; /** * Defines values for Expander. @@ -2312,6 +2482,46 @@ export type ManagedClustersUpdateTagsResponse = ManagedCluster & { }; }; +/** + * Contains response data for the runCommand operation. + */ +export type ManagedClustersRunCommandResponse = RunCommandResult & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: RunCommandResult; + }; +}; + +/** + * Contains response data for the getCommandResult operation. + */ +export type ManagedClustersGetCommandResultResponse = RunCommandResult & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: RunCommandResult; + }; +}; + /** * Contains response data for the beginCreateOrUpdate operation. */ @@ -2352,6 +2562,26 @@ export type ManagedClustersBeginUpdateTagsResponse = ManagedCluster & { }; }; +/** + * Contains response data for the beginRunCommand operation. + */ +export type ManagedClustersBeginRunCommandResponse = RunCommandResult & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: RunCommandResult; + }; +}; + /** * Contains response data for the listNext operation. */ diff --git a/sdk/containerservice/arm-containerservice/src/models/maintenanceConfigurationsMappers.ts b/sdk/containerservice/arm-containerservice/src/models/maintenanceConfigurationsMappers.ts index cb88910b32f3..29b0fd9fd93e 100644 --- a/sdk/containerservice/arm-containerservice/src/models/maintenanceConfigurationsMappers.ts +++ b/sdk/containerservice/arm-containerservice/src/models/maintenanceConfigurationsMappers.ts @@ -28,6 +28,7 @@ export { ManagedClusterAgentPoolProfileProperties, ManagedClusterAPIServerAccessProfile, ManagedClusterAutoUpgradeProfile, + ManagedClusterHTTPProxyConfig, ManagedClusterIdentity, ManagedClusterIdentityUserAssignedIdentitiesValue, ManagedClusterLoadBalancerProfile, @@ -46,6 +47,7 @@ export { PowerState, PrivateEndpoint, PrivateEndpointConnection, + PrivateLinkResource, PrivateLinkServiceConnectionState, Resource, ResourceReference, diff --git a/sdk/containerservice/arm-containerservice/src/models/managedClustersMappers.ts b/sdk/containerservice/arm-containerservice/src/models/managedClustersMappers.ts index 3128db3eaae9..1aaebf44754f 100644 --- a/sdk/containerservice/arm-containerservice/src/models/managedClustersMappers.ts +++ b/sdk/containerservice/arm-containerservice/src/models/managedClustersMappers.ts @@ -29,6 +29,7 @@ export { ManagedClusterAgentPoolProfileProperties, ManagedClusterAPIServerAccessProfile, ManagedClusterAutoUpgradeProfile, + ManagedClusterHTTPProxyConfig, ManagedClusterIdentity, ManagedClusterIdentityUserAssignedIdentitiesValue, ManagedClusterListResult, @@ -51,9 +52,12 @@ export { PowerState, PrivateEndpoint, PrivateEndpointConnection, + PrivateLinkResource, PrivateLinkServiceConnectionState, Resource, ResourceReference, + RunCommandRequest, + RunCommandResult, SubResource, SysctlConfig, SystemData, diff --git a/sdk/containerservice/arm-containerservice/src/models/mappers.ts b/sdk/containerservice/arm-containerservice/src/models/mappers.ts index 7d38494880bb..8890cd378f65 100644 --- a/sdk/containerservice/arm-containerservice/src/models/mappers.ts +++ b/sdk/containerservice/arm-containerservice/src/models/mappers.ts @@ -641,6 +641,12 @@ export const ManagedClusterAgentPoolProfileProperties: msRest.CompositeMapper = name: "String" } }, + osSKU: { + serializedName: "osSKU", + type: { + name: "String" + } + }, maxCount: { serializedName: "maxCount", type: { @@ -723,6 +729,12 @@ export const ManagedClusterAgentPoolProfileProperties: msRest.CompositeMapper = name: "Boolean" } }, + nodePublicIPPrefixID: { + serializedName: "nodePublicIPPrefixID", + type: { + name: "String" + } + }, scaleSetPriority: { serializedName: "scaleSetPriority", defaultValue: 'Regular', @@ -801,6 +813,18 @@ export const ManagedClusterAgentPoolProfileProperties: msRest.CompositeMapper = type: { name: "Boolean" } + }, + enableFIPS: { + serializedName: "enableFIPS", + type: { + name: "Boolean" + } + }, + gpuInstanceProfile: { + serializedName: "gpuInstanceProfile", + type: { + name: "String" + } } } } @@ -889,6 +913,12 @@ export const AgentPool: msRest.CompositeMapper = { name: "String" } }, + osSKU: { + serializedName: "properties.osSKU", + type: { + name: "String" + } + }, maxCount: { serializedName: "properties.maxCount", type: { @@ -971,6 +1001,12 @@ export const AgentPool: msRest.CompositeMapper = { name: "Boolean" } }, + nodePublicIPPrefixID: { + serializedName: "properties.nodePublicIPPrefixID", + type: { + name: "String" + } + }, scaleSetPriority: { serializedName: "properties.scaleSetPriority", defaultValue: 'Regular', @@ -1049,6 +1085,18 @@ export const AgentPool: msRest.CompositeMapper = { type: { name: "Boolean" } + }, + enableFIPS: { + serializedName: "properties.enableFIPS", + type: { + name: "Boolean" + } + }, + gpuInstanceProfile: { + serializedName: "properties.gpuInstanceProfile", + type: { + name: "String" + } } } } @@ -1078,6 +1126,12 @@ export const ManagedClusterWindowsProfile: msRest.CompositeMapper = { type: { name: "String" } + }, + enableCSIProxy: { + serializedName: "enableCSIProxy", + type: { + name: "Boolean" + } } } } @@ -1524,6 +1578,94 @@ export const MaintenanceConfiguration: msRest.CompositeMapper = { } }; +export const RunCommandRequest: msRest.CompositeMapper = { + serializedName: "RunCommandRequest", + type: { + name: "Composite", + className: "RunCommandRequest", + modelProperties: { + command: { + required: true, + serializedName: "command", + type: { + name: "String" + } + }, + context: { + serializedName: "context", + type: { + name: "String" + } + }, + clusterToken: { + serializedName: "clusterToken", + type: { + name: "String" + } + } + } + } +}; + +export const RunCommandResult: msRest.CompositeMapper = { + serializedName: "RunCommandResult", + type: { + name: "Composite", + className: "RunCommandResult", + modelProperties: { + id: { + readOnly: true, + serializedName: "id", + type: { + name: "String" + } + }, + provisioningState: { + readOnly: true, + serializedName: "properties.provisioningState", + type: { + name: "String" + } + }, + exitCode: { + readOnly: true, + serializedName: "properties.exitCode", + type: { + name: "Number" + } + }, + startedAt: { + readOnly: true, + serializedName: "properties.startedAt", + type: { + name: "DateTime" + } + }, + finishedAt: { + readOnly: true, + serializedName: "properties.finishedAt", + type: { + name: "DateTime" + } + }, + logs: { + readOnly: true, + serializedName: "properties.logs", + type: { + name: "String" + } + }, + reason: { + readOnly: true, + serializedName: "properties.reason", + type: { + name: "String" + } + } + } + } +}; + export const ContainerServiceVMDiagnostics: msRest.CompositeMapper = { serializedName: "ContainerServiceVMDiagnostics", type: { @@ -1678,6 +1820,12 @@ export const ManagedClusterPodIdentity: msRest.CompositeMapper = { name: "String" } }, + bindingSelector: { + serializedName: "bindingSelector", + type: { + name: "String" + } + }, identity: { required: true, serializedName: "identity", @@ -1753,6 +1901,12 @@ export const ManagedClusterPodIdentityProfile: msRest.CompositeMapper = { name: "Boolean" } }, + allowNetworkPluginKubenet: { + serializedName: "allowNetworkPluginKubenet", + type: { + name: "Boolean" + } + }, userAssignedIdentities: { serializedName: "userAssignedIdentities", type: { @@ -2010,6 +2164,97 @@ export const ManagedClusterPropertiesIdentityProfileValue: msRest.CompositeMappe } }; +export const PrivateLinkResource: msRest.CompositeMapper = { + serializedName: "PrivateLinkResource", + type: { + name: "Composite", + className: "PrivateLinkResource", + modelProperties: { + id: { + serializedName: "id", + type: { + name: "String" + } + }, + name: { + serializedName: "name", + type: { + name: "String" + } + }, + type: { + serializedName: "type", + type: { + name: "String" + } + }, + groupId: { + serializedName: "groupId", + type: { + name: "String" + } + }, + requiredMembers: { + serializedName: "requiredMembers", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + privateLinkServiceID: { + readOnly: true, + serializedName: "privateLinkServiceID", + type: { + name: "String" + } + } + } + } +}; + +export const ManagedClusterHTTPProxyConfig: msRest.CompositeMapper = { + serializedName: "ManagedClusterHTTPProxyConfig", + type: { + name: "Composite", + className: "ManagedClusterHTTPProxyConfig", + modelProperties: { + httpProxy: { + serializedName: "httpProxy", + type: { + name: "String" + } + }, + httpsProxy: { + serializedName: "httpsProxy", + type: { + name: "String" + } + }, + noProxy: { + serializedName: "noProxy", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + trustedCa: { + serializedName: "trustedCa", + type: { + name: "String" + } + } + } + } +}; + export const ManagedClusterIdentityUserAssignedIdentitiesValue: msRest.CompositeMapper = { serializedName: "ManagedClusterIdentity_userAssignedIdentitiesValue", type: { @@ -2144,6 +2389,12 @@ export const ManagedCluster: msRest.CompositeMapper = { name: "String" } }, + fqdnSubdomain: { + serializedName: "properties.fqdnSubdomain", + type: { + name: "String" + } + }, fqdn: { readOnly: true, serializedName: "properties.fqdn", @@ -2158,6 +2409,13 @@ export const ManagedCluster: msRest.CompositeMapper = { name: "String" } }, + azurePortalFQDN: { + readOnly: true, + serializedName: "properties.azurePortalFQDN", + type: { + name: "String" + } + }, agentPoolProfiles: { serializedName: "properties.agentPoolProfiles", type: { @@ -2281,6 +2539,31 @@ export const ManagedCluster: msRest.CompositeMapper = { } } }, + privateLinkResources: { + serializedName: "properties.privateLinkResources", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "PrivateLinkResource" + } + } + } + }, + disableLocalAccounts: { + serializedName: "properties.disableLocalAccounts", + type: { + name: "Boolean" + } + }, + httpProxyConfig: { + serializedName: "properties.httpProxyConfig", + type: { + name: "Composite", + className: "ManagedClusterHTTPProxyConfig" + } + }, identity: { serializedName: "identity", type: { @@ -2750,58 +3033,6 @@ export const PrivateEndpointConnectionListResult: msRest.CompositeMapper = { } }; -export const PrivateLinkResource: msRest.CompositeMapper = { - serializedName: "PrivateLinkResource", - type: { - name: "Composite", - className: "PrivateLinkResource", - modelProperties: { - id: { - serializedName: "id", - type: { - name: "String" - } - }, - name: { - serializedName: "name", - type: { - name: "String" - } - }, - type: { - serializedName: "type", - type: { - name: "String" - } - }, - groupId: { - serializedName: "groupId", - type: { - name: "String" - } - }, - requiredMembers: { - serializedName: "requiredMembers", - type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } - } - }, - privateLinkServiceID: { - readOnly: true, - serializedName: "privateLinkServiceID", - type: { - name: "String" - } - } - } - } -}; - export const PrivateLinkResourcesListResult: msRest.CompositeMapper = { serializedName: "PrivateLinkResourcesListResult", type: { diff --git a/sdk/containerservice/arm-containerservice/src/models/parameters.ts b/sdk/containerservice/arm-containerservice/src/models/parameters.ts index 27b330139896..22ec9b2106e4 100644 --- a/sdk/containerservice/arm-containerservice/src/models/parameters.ts +++ b/sdk/containerservice/arm-containerservice/src/models/parameters.ts @@ -39,6 +39,16 @@ export const apiVersion: msRest.OperationQueryParameter = { } } }; +export const commandId: msRest.OperationURLParameter = { + parameterPath: "commandId", + mapper: { + required: true, + serializedName: "commandId", + type: { + name: "String" + } + } +}; export const configName: msRest.OperationURLParameter = { parameterPath: "configName", mapper: { diff --git a/sdk/containerservice/arm-containerservice/src/models/privateEndpointConnectionsMappers.ts b/sdk/containerservice/arm-containerservice/src/models/privateEndpointConnectionsMappers.ts index b507c48ec66e..ac982ea08620 100644 --- a/sdk/containerservice/arm-containerservice/src/models/privateEndpointConnectionsMappers.ts +++ b/sdk/containerservice/arm-containerservice/src/models/privateEndpointConnectionsMappers.ts @@ -27,6 +27,7 @@ export { ManagedClusterAgentPoolProfileProperties, ManagedClusterAPIServerAccessProfile, ManagedClusterAutoUpgradeProfile, + ManagedClusterHTTPProxyConfig, ManagedClusterIdentity, ManagedClusterIdentityUserAssignedIdentitiesValue, ManagedClusterLoadBalancerProfile, @@ -46,6 +47,7 @@ export { PrivateEndpoint, PrivateEndpointConnection, PrivateEndpointConnectionListResult, + PrivateLinkResource, PrivateLinkServiceConnectionState, Resource, ResourceReference, diff --git a/sdk/containerservice/arm-containerservice/src/operations/managedClusters.ts b/sdk/containerservice/arm-containerservice/src/operations/managedClusters.ts index a3a0ee7f1249..390e1fded82b 100644 --- a/sdk/containerservice/arm-containerservice/src/operations/managedClusters.ts +++ b/sdk/containerservice/arm-containerservice/src/operations/managedClusters.ts @@ -404,6 +404,58 @@ export class ManagedClusters { .then(lroPoller => lroPoller.pollUntilFinished()); } + /** + * Submit a command to run against managed kubernetes service, it will create a pod to run the + * command. + * @summary Run Command against Managed Kubernetes Service + * @param resourceGroupName The name of the resource group. + * @param resourceName The name of the managed cluster resource. + * @param requestPayload Parameters supplied to the RunCommand operation. + * @param [options] The optional parameters + * @returns Promise + */ + runCommand(resourceGroupName: string, resourceName: string, requestPayload: Models.RunCommandRequest, options?: msRest.RequestOptionsBase): Promise { + return this.beginRunCommand(resourceGroupName,resourceName,requestPayload,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Get command result from previous runCommand invoke. + * @summary Get command result. + * @param resourceGroupName The name of the resource group. + * @param resourceName The name of the managed cluster resource. + * @param commandId Id of the command request. + * @param [options] The optional parameters + * @returns Promise + */ + getCommandResult(resourceGroupName: string, resourceName: string, commandId: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName The name of the resource group. + * @param resourceName The name of the managed cluster resource. + * @param commandId Id of the command request. + * @param callback The callback + */ + getCommandResult(resourceGroupName: string, resourceName: string, commandId: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName The name of the resource group. + * @param resourceName The name of the managed cluster resource. + * @param commandId Id of the command request. + * @param options The optional parameters + * @param callback The callback + */ + getCommandResult(resourceGroupName: string, resourceName: string, commandId: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + getCommandResult(resourceGroupName: string, resourceName: string, commandId: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + resourceName, + commandId, + options + }, + getCommandResultOperationSpec, + callback) as Promise; + } + /** * Creates or updates a managed cluster with the specified configuration for agents and Kubernetes * version. @@ -566,6 +618,28 @@ export class ManagedClusters { options); } + /** + * Submit a command to run against managed kubernetes service, it will create a pod to run the + * command. + * @summary Run Command against Managed Kubernetes Service + * @param resourceGroupName The name of the resource group. + * @param resourceName The name of the managed cluster resource. + * @param requestPayload Parameters supplied to the RunCommand operation. + * @param [options] The optional parameters + * @returns Promise + */ + beginRunCommand(resourceGroupName: string, resourceName: string, requestPayload: Models.RunCommandRequest, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + resourceName, + requestPayload, + options + }, + beginRunCommandOperationSpec, + options); + } + /** * Gets a list of managed clusters in the specified subscription. The operation returns properties * of each managed cluster. @@ -827,6 +901,33 @@ const getOperationSpec: msRest.OperationSpec = { serializer }; +const getCommandResultOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}/commandResults/{commandId}", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.resourceName, + Parameters.commandId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.RunCommandResult + }, + 202: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + const beginCreateOrUpdateOperationSpec: msRest.OperationSpec = { httpMethod: "PUT", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}", @@ -1052,6 +1153,39 @@ const beginStartOperationSpec: msRest.OperationSpec = { serializer }; +const beginRunCommandOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}/runCommand", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.resourceName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "requestPayload", + mapper: { + ...Mappers.RunCommandRequest, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.RunCommandResult + }, + 202: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + const listNextOperationSpec: msRest.OperationSpec = { httpMethod: "GET", baseUrl: "https://management.azure.com",