private ManagedClusterAADProfile GetAadProfile() { ManagedClusterAADProfile aadProfile = null; //if (!string.IsNullOrEmpty(AadProfileClientAppId) || !string.IsNullOrEmpty(AadProfileServerAppId) || // !string.IsNullOrEmpty(AadProfileServerAppSecret) || !string.IsNullOrEmpty(AadProfileTenantId)) //{ // aadProfile = new ManagedClusterAADProfile(clientAppID: AadProfileClientAppId, serverAppID: AadProfileServerAppId, // serverAppSecret: AadProfileServerAppSecret, tenantID: AadProfileTenantId); //} return(aadProfile); }
/// <summary> /// Reset AAD Profile of a managed cluster. /// </summary> /// <remarks> /// Update the AAD Profile for a managed cluster. /// </remarks> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// The name of the resource group. /// </param> /// <param name='resourceName'> /// The name of the managed cluster resource. /// </param> /// <param name='parameters'> /// Parameters supplied to the Reset AAD Profile operation for a Managed /// Cluster. /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task BeginResetAADProfileAsync(this IManagedClustersOperations operations, string resourceGroupName, string resourceName, ManagedClusterAADProfile parameters, CancellationToken cancellationToken = default(CancellationToken)) { (await operations.BeginResetAADProfileWithHttpMessagesAsync(resourceGroupName, resourceName, parameters, null, cancellationToken).ConfigureAwait(false)).Dispose(); }
/// <summary> /// Reset AAD Profile of a managed cluster. /// </summary> /// <remarks> /// Update the AAD Profile for a managed cluster. /// </remarks> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// The name of the resource group. /// </param> /// <param name='resourceName'> /// The name of the managed cluster resource. /// </param> /// <param name='parameters'> /// Parameters supplied to the Reset AAD Profile operation for a Managed /// Cluster. /// </param> public static void BeginResetAADProfile(this IManagedClustersOperations operations, string resourceGroupName, string resourceName, ManagedClusterAADProfile parameters) { operations.BeginResetAADProfileAsync(resourceGroupName, resourceName, parameters).GetAwaiter().GetResult(); }