Skip to content

Commit

Permalink
CodeGen from PR 11588 in Azure/azure-rest-api-specs
Browse files Browse the repository at this point in the history
Dev containerservice microsoft.container service 2020 11 01 (Azure#11588)

* Adds base for updating Microsoft.ContainerService from version stable/2020-09-01 to version 2020-11-01

* Updates readme

* Updates API version in new specs and examples

* add autoupgradeprofile to 2020-11-01 (Azure#11363)

* add autoupgradeprofile

* add autoupgrader profile to mc

* format change

Co-authored-by: Xiahe Liu <Xiahe.Liu@microsoft.com>

* add pod subnet id on agentpool (Azure#11310)

* aks: add pod identity profile spec (Azure#11366)

* add private dns zone property in 2020-11-01 (Azure#11311)

Co-authored-by: Li Ma <lima2@microsoft.com>

* Remove invalid pattern and adjust description (Azure#11312)

* aks: fix pod identity profile field names (Azure#11484)

* aks: add missing `podIdentityProfile.enabled` field

* aks: typo

* add non upgrade channel (Azure#11492)

Co-authored-by: Xiahe Liu <Xiahe.Liu@microsoft.com>

* Make identityProfile mutable (Azure#11458)

* Add KubeletConfig and LinuxOSConfig specs (Azure#11490)

* aks: update readme tag for 1101 (Azure#11472)

* aks: update readme tag

* aks: add `2020-11-01-only`

* resovle merge conlicts to master, adding recent master change to dev branch (Azure#11604)

Co-authored-by: Xiahe Liu <Xiahe.Liu@microsoft.com>

Co-authored-by: Xiahe Liu <Xiahe.Liu@microsoft.com>
Co-authored-by: Paul Miller <pmiller@microsoft.com>
Co-authored-by: hbc <me@hbc.rocks>
Co-authored-by: Super <mali_no2@hotmail.com>
Co-authored-by: Li Ma <lima2@microsoft.com>
Co-authored-by: Qingchuan Hao <haoqingchuan@hotmail.com>
Co-authored-by: Tongyao Si <tosi@microsoft.com>
Co-authored-by: Bo Wang <61758179+bowang-666@users.noreply.github.com>
Co-authored-by: Phoenix He <tih@microsoft.com>
  • Loading branch information
10 people committed Nov 11, 2020
1 parent 79b0fdf commit 2b1b466
Show file tree
Hide file tree
Showing 20 changed files with 2,346 additions and 2,826 deletions.
15 changes: 7 additions & 8 deletions sdk/containerservice/arm-containerservice/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ npm install @azure/arm-containerservice

### How to use

#### nodejs - Authentication, client creation and list openShiftManagedClusters as an example written in TypeScript.
#### nodejs - client creation and list operations as an example written in TypeScript.

##### Install @azure/ms-rest-nodeauth

Expand All @@ -26,16 +26,15 @@ npm install @azure/ms-rest-nodeauth@"^3.0.0"

##### Sample code

While the below sample uses the interactive login, other authentication options can be found in the [README.md file of @azure/ms-rest-nodeauth](https://www.npmjs.com/package/@azure/ms-rest-nodeauth) package
```typescript
import * as msRest from "@azure/ms-rest-js";
import * as msRestAzure from "@azure/ms-rest-azure-js";
import * as msRestNodeAuth from "@azure/ms-rest-nodeauth";
import { ContainerServiceClient, ContainerServiceModels, ContainerServiceMappers } from "@azure/arm-containerservice";
const msRestNodeAuth = require("@azure/ms-rest-nodeauth");
const { ContainerServiceClient } = require("@azure/arm-containerservice");
const subscriptionId = process.env["AZURE_SUBSCRIPTION_ID"];

msRestNodeAuth.interactiveLogin().then((creds) => {
const client = new ContainerServiceClient(creds, subscriptionId);
client.openShiftManagedClusters.list().then((result) => {
client.operations.list().then((result) => {
console.log("The result is:");
console.log(result);
});
Expand All @@ -44,7 +43,7 @@ msRestNodeAuth.interactiveLogin().then((creds) => {
});
```

#### browser - Authentication, client creation and list openShiftManagedClusters as an example written in JavaScript.
#### browser - Authentication, client creation and list operations as an example written in JavaScript.

##### Install @azure/ms-rest-browserauth

Expand Down Expand Up @@ -78,7 +77,7 @@ See https://github.com/Azure/ms-rest-browserauth to learn how to authenticate to
authManager.login();
}
const client = new Azure.ArmContainerservice.ContainerServiceClient(res.creds, subscriptionId);
client.openShiftManagedClusters.list().then((result) => {
client.operations.list().then((result) => {
console.log("The result is:");
console.log(result);
}).catch((err) => {
Expand Down
4 changes: 2 additions & 2 deletions sdk/containerservice/arm-containerservice/rollup.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ const config = {
"@azure/ms-rest-azure-js": "msRestAzure"
},
banner: `/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is
Expand All @@ -17,12 +16,12 @@ import { ContainerServiceClientContext } from "./containerServiceClientContext";

class ContainerServiceClient extends ContainerServiceClientContext {
// Operation groups
openShiftManagedClusters: operations.OpenShiftManagedClusters;
containerServices: operations.ContainerServices;
operations: operations.Operations;
managedClusters: operations.ManagedClusters;
agentPools: operations.AgentPools;
privateEndpointConnections: operations.PrivateEndpointConnections;
privateLinkResources: operations.PrivateLinkResources;
resolvePrivateLinkServiceId: operations.ResolvePrivateLinkServiceId;

/**
* Initializes a new instance of the ContainerServiceClient class.
Expand All @@ -33,12 +32,12 @@ class ContainerServiceClient extends ContainerServiceClientContext {
*/
constructor(credentials: msRest.ServiceClientCredentials, subscriptionId: string, options?: Models.ContainerServiceClientOptions) {
super(credentials, subscriptionId, options);
this.openShiftManagedClusters = new operations.OpenShiftManagedClusters(this);
this.containerServices = new operations.ContainerServices(this);
this.operations = new operations.Operations(this);
this.managedClusters = new operations.ManagedClusters(this);
this.agentPools = new operations.AgentPools(this);
this.privateEndpointConnections = new operations.PrivateEndpointConnections(this);
this.privateLinkResources = new operations.PrivateLinkResources(this);
this.resolvePrivateLinkServiceId = new operations.ResolvePrivateLinkServiceId(this);
}
}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is
Expand All @@ -18,6 +17,7 @@ const packageVersion = "11.2.0";
export class ContainerServiceClientContext extends msRestAzure.AzureServiceClient {
credentials: msRest.ServiceClientCredentials;
subscriptionId: string;
apiVersion?: string;

/**
* Initializes a new instance of the ContainerServiceClient class.
Expand All @@ -37,24 +37,25 @@ export class ContainerServiceClientContext extends msRestAzure.AzureServiceClien
if (!options) {
options = {};
}
if (!options.userAgent) {
if(!options.userAgent) {
const defaultUserAgent = msRestAzure.getDefaultUserAgentValue();
options.userAgent = `${packageName}/${packageVersion} ${defaultUserAgent}`;
}

super(credentials, options);

this.apiVersion = '2020-11-01';
this.acceptLanguage = 'en-US';
this.longRunningOperationRetryTimeout = 30;
this.baseUri = options.baseUri || this.baseUri || "https://management.azure.com";
this.requestContentType = "application/json; charset=utf-8";
this.credentials = credentials;
this.subscriptionId = subscriptionId;

if (options.acceptLanguage !== null && options.acceptLanguage !== undefined) {
if(options.acceptLanguage !== null && options.acceptLanguage !== undefined) {
this.acceptLanguage = options.acceptLanguage;
}
if (options.longRunningOperationRetryTimeout !== null && options.longRunningOperationRetryTimeout !== undefined) {
if(options.longRunningOperationRetryTimeout !== null && options.longRunningOperationRetryTimeout !== undefined) {
this.longRunningOperationRetryTimeout = options.longRunningOperationRetryTimeout;
}
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/

export {
discriminators,
AgentPool,
AgentPoolAvailableVersions,
AgentPoolAvailableVersionsPropertiesAgentPoolVersionsItem,
Expand All @@ -17,20 +16,12 @@ export {
AgentPoolUpgradeSettings,
BaseResource,
CloudError,
ContainerService,
ContainerServiceAgentPoolProfile,
ContainerServiceCustomProfile,
ContainerServiceDiagnosticsProfile,
ContainerServiceLinuxProfile,
ContainerServiceMasterProfile,
ContainerServiceNetworkProfile,
ContainerServiceOrchestratorProfile,
ContainerServiceServicePrincipalProfile,
ContainerServiceSshConfiguration,
ContainerServiceSshPublicKey,
ContainerServiceVMDiagnostics,
ContainerServiceWindowsProfile,
KeyVaultSecretRef,
KubeletConfig,
LinuxOSConfig,
ManagedCluster,
ManagedClusterAADProfile,
ManagedClusterAccessProfile,
Expand All @@ -39,32 +30,29 @@ export {
ManagedClusterAgentPoolProfile,
ManagedClusterAgentPoolProfileProperties,
ManagedClusterAPIServerAccessProfile,
ManagedClusterAutoUpgradeProfile,
ManagedClusterIdentity,
ManagedClusterIdentityUserAssignedIdentitiesValue,
ManagedClusterLoadBalancerProfile,
ManagedClusterLoadBalancerProfileManagedOutboundIPs,
ManagedClusterLoadBalancerProfileOutboundIPPrefixes,
ManagedClusterLoadBalancerProfileOutboundIPs,
ManagedClusterPodIdentity,
ManagedClusterPodIdentityException,
ManagedClusterPodIdentityProfile,
ManagedClusterPodIdentityProvisioningInfo,
ManagedClusterPropertiesAutoScalerProfile,
ManagedClusterPropertiesIdentityProfileValue,
ManagedClusterServicePrincipalProfile,
ManagedClusterSKU,
ManagedClusterWindowsProfile,
NetworkProfile,
OpenShiftManagedCluster,
OpenShiftManagedClusterAADIdentityProvider,
OpenShiftManagedClusterAgentPoolProfile,
OpenShiftManagedClusterAuthProfile,
OpenShiftManagedClusterBaseIdentityProvider,
OpenShiftManagedClusterIdentityProvider,
OpenShiftManagedClusterMasterPoolProfile,
OpenShiftRouterProfile,
PowerState,
PrivateEndpoint,
PrivateEndpointConnection,
PrivateLinkServiceConnectionState,
PurchasePlan,
Resource,
ResourceReference,
SubResource,
SysctlConfig,
UserAssignedIdentity
} from "../models/mappers";
Loading

0 comments on commit 2b1b466

Please sign in to comment.