All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.azure.containerservice.kotlin.KubernetesCluster.kt Maven / Gradle / Ivy

@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.azure.containerservice.kotlin

import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterAciConnectorLinux
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterApiServerAccessProfile
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterAutoScalerProfile
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterAzureActiveDirectoryRoleBasedAccessControl
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterConfidentialComputing
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterDefaultNodePool
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterHttpProxyConfig
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterIdentity
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterIngressApplicationGateway
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterKeyManagementService
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterKeyVaultSecretsProvider
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterKubeAdminConfig
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterKubeConfig
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterKubeletIdentity
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterLinuxProfile
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterMaintenanceWindow
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterMaintenanceWindowAutoUpgrade
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterMaintenanceWindowNodeOs
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterMicrosoftDefender
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterMonitorMetrics
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterNetworkProfile
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterOmsAgent
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterServiceMeshProfile
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterServicePrincipal
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterStorageProfile
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterWebAppRouting
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterWindowsProfile
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterWorkloadAutoscalerProfile
import com.pulumi.core.Output
import com.pulumi.kotlin.KotlinCustomResource
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.ResourceMapper
import com.pulumi.kotlin.options.CustomResourceOptions
import com.pulumi.kotlin.options.CustomResourceOptionsBuilder
import com.pulumi.resources.Resource
import kotlin.Boolean
import kotlin.Deprecated
import kotlin.Int
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.collections.Map
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterAciConnectorLinux.Companion.toKotlin as kubernetesClusterAciConnectorLinuxToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterApiServerAccessProfile.Companion.toKotlin as kubernetesClusterApiServerAccessProfileToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterAutoScalerProfile.Companion.toKotlin as kubernetesClusterAutoScalerProfileToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterAzureActiveDirectoryRoleBasedAccessControl.Companion.toKotlin as kubernetesClusterAzureActiveDirectoryRoleBasedAccessControlToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterConfidentialComputing.Companion.toKotlin as kubernetesClusterConfidentialComputingToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterDefaultNodePool.Companion.toKotlin as kubernetesClusterDefaultNodePoolToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterHttpProxyConfig.Companion.toKotlin as kubernetesClusterHttpProxyConfigToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterIdentity.Companion.toKotlin as kubernetesClusterIdentityToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterIngressApplicationGateway.Companion.toKotlin as kubernetesClusterIngressApplicationGatewayToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterKeyManagementService.Companion.toKotlin as kubernetesClusterKeyManagementServiceToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterKeyVaultSecretsProvider.Companion.toKotlin as kubernetesClusterKeyVaultSecretsProviderToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterKubeAdminConfig.Companion.toKotlin as kubernetesClusterKubeAdminConfigToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterKubeConfig.Companion.toKotlin as kubernetesClusterKubeConfigToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterKubeletIdentity.Companion.toKotlin as kubernetesClusterKubeletIdentityToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterLinuxProfile.Companion.toKotlin as kubernetesClusterLinuxProfileToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterMaintenanceWindow.Companion.toKotlin as kubernetesClusterMaintenanceWindowToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterMaintenanceWindowAutoUpgrade.Companion.toKotlin as kubernetesClusterMaintenanceWindowAutoUpgradeToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterMaintenanceWindowNodeOs.Companion.toKotlin as kubernetesClusterMaintenanceWindowNodeOsToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterMicrosoftDefender.Companion.toKotlin as kubernetesClusterMicrosoftDefenderToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterMonitorMetrics.Companion.toKotlin as kubernetesClusterMonitorMetricsToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterNetworkProfile.Companion.toKotlin as kubernetesClusterNetworkProfileToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterOmsAgent.Companion.toKotlin as kubernetesClusterOmsAgentToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterServiceMeshProfile.Companion.toKotlin as kubernetesClusterServiceMeshProfileToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterServicePrincipal.Companion.toKotlin as kubernetesClusterServicePrincipalToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterStorageProfile.Companion.toKotlin as kubernetesClusterStorageProfileToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterWebAppRouting.Companion.toKotlin as kubernetesClusterWebAppRoutingToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterWindowsProfile.Companion.toKotlin as kubernetesClusterWindowsProfileToKotlin
import com.pulumi.azure.containerservice.kotlin.outputs.KubernetesClusterWorkloadAutoscalerProfile.Companion.toKotlin as kubernetesClusterWorkloadAutoscalerProfileToKotlin

/**
 * Builder for [KubernetesCluster].
 */
@PulumiTagMarker
public class KubernetesClusterResourceBuilder internal constructor() {
    public var name: String? = null

    public var args: KubernetesClusterArgs = KubernetesClusterArgs()

    public var opts: CustomResourceOptions = CustomResourceOptions()

    /**
     * @param name The _unique_ name of the resulting resource.
     */
    public fun name(`value`: String) {
        this.name = value
    }

    /**
     * @param block The arguments to use to populate this resource's properties.
     */
    public suspend fun args(block: suspend KubernetesClusterArgsBuilder.() -> Unit) {
        val builder = KubernetesClusterArgsBuilder()
        block(builder)
        this.args = builder.build()
    }

    /**
     * @param block A bag of options that control this resource's behavior.
     */
    public suspend fun opts(block: suspend CustomResourceOptionsBuilder.() -> Unit) {
        this.opts = com.pulumi.kotlin.options.CustomResourceOptions.opts(block)
    }

    internal fun build(): KubernetesCluster {
        val builtJavaResource =
            com.pulumi.azure.containerservice.KubernetesCluster(
                this.name,
                this.args.toJava(),
                this.opts.toJava(),
            )
        return KubernetesCluster(builtJavaResource)
    }
}

/**
 * Manages a Managed Kubernetes Cluster (also known as AKS / Azure Kubernetes Service)
 * ## Example Usage
 * This example provisions a basic Managed Kubernetes Cluster.
 * 
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as azure from "@pulumi/azure";
 * const example = new azure.core.ResourceGroup("example", {
 *     name: "example-resources",
 *     location: "West Europe",
 * });
 * const exampleKubernetesCluster = new azure.containerservice.KubernetesCluster("example", {
 *     name: "example-aks1",
 *     location: example.location,
 *     resourceGroupName: example.name,
 *     dnsPrefix: "exampleaks1",
 *     defaultNodePool: {
 *         name: "default",
 *         nodeCount: 1,
 *         vmSize: "Standard_D2_v2",
 *     },
 *     identity: {
 *         type: "SystemAssigned",
 *     },
 *     tags: {
 *         Environment: "Production",
 *     },
 * });
 * export const clientCertificate = exampleKubernetesCluster.kubeConfigs.apply(kubeConfigs => kubeConfigs[0].clientCertificate);
 * export const kubeConfig = exampleKubernetesCluster.kubeConfigRaw;
 * ```
 * ```python
 * import pulumi
 * import pulumi_azure as azure
 * example = azure.core.ResourceGroup("example",
 *     name="example-resources",
 *     location="West Europe")
 * example_kubernetes_cluster = azure.containerservice.KubernetesCluster("example",
 *     name="example-aks1",
 *     location=example.location,
 *     resource_group_name=example.name,
 *     dns_prefix="exampleaks1",
 *     default_node_pool={
 *         "name": "default",
 *         "node_count": 1,
 *         "vm_size": "Standard_D2_v2",
 *     },
 *     identity={
 *         "type": "SystemAssigned",
 *     },
 *     tags={
 *         "Environment": "Production",
 *     })
 * pulumi.export("clientCertificate", example_kubernetes_cluster.kube_configs[0].client_certificate)
 * pulumi.export("kubeConfig", example_kubernetes_cluster.kube_config_raw)
 * ```
 * ```csharp
 * using System.Collections.Generic;
 * using System.Linq;
 * using Pulumi;
 * using Azure = Pulumi.Azure;
 * return await Deployment.RunAsync(() =>
 * {
 *     var example = new Azure.Core.ResourceGroup("example", new()
 *     {
 *         Name = "example-resources",
 *         Location = "West Europe",
 *     });
 *     var exampleKubernetesCluster = new Azure.ContainerService.KubernetesCluster("example", new()
 *     {
 *         Name = "example-aks1",
 *         Location = example.Location,
 *         ResourceGroupName = example.Name,
 *         DnsPrefix = "exampleaks1",
 *         DefaultNodePool = new Azure.ContainerService.Inputs.KubernetesClusterDefaultNodePoolArgs
 *         {
 *             Name = "default",
 *             NodeCount = 1,
 *             VmSize = "Standard_D2_v2",
 *         },
 *         Identity = new Azure.ContainerService.Inputs.KubernetesClusterIdentityArgs
 *         {
 *             Type = "SystemAssigned",
 *         },
 *         Tags =
 *         {
 *             { "Environment", "Production" },
 *         },
 *     });
 *     return new Dictionary
 *     {
 *         ["clientCertificate"] = exampleKubernetesCluster.KubeConfigs.Apply(kubeConfigs => kubeConfigs[0].ClientCertificate),
 *         ["kubeConfig"] = exampleKubernetesCluster.KubeConfigRaw,
 *     };
 * });
 * ```
 * ```go
 * package main
 * import (
 * 	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/containerservice"
 * 	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/core"
 * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
 * )
 * func main() {
 * 	pulumi.Run(func(ctx *pulumi.Context) error {
 * 		example, err := core.NewResourceGroup(ctx, "example", &core.ResourceGroupArgs{
 * 			Name:     pulumi.String("example-resources"),
 * 			Location: pulumi.String("West Europe"),
 * 		})
 * 		if err != nil {
 * 			return err
 * 		}
 * 		exampleKubernetesCluster, err := containerservice.NewKubernetesCluster(ctx, "example", &containerservice.KubernetesClusterArgs{
 * 			Name:              pulumi.String("example-aks1"),
 * 			Location:          example.Location,
 * 			ResourceGroupName: example.Name,
 * 			DnsPrefix:         pulumi.String("exampleaks1"),
 * 			DefaultNodePool: &containerservice.KubernetesClusterDefaultNodePoolArgs{
 * 				Name:      pulumi.String("default"),
 * 				NodeCount: pulumi.Int(1),
 * 				VmSize:    pulumi.String("Standard_D2_v2"),
 * 			},
 * 			Identity: &containerservice.KubernetesClusterIdentityArgs{
 * 				Type: pulumi.String("SystemAssigned"),
 * 			},
 * 			Tags: pulumi.StringMap{
 * 				"Environment": pulumi.String("Production"),
 * 			},
 * 		})
 * 		if err != nil {
 * 			return err
 * 		}
 * 		ctx.Export("clientCertificate", exampleKubernetesCluster.KubeConfigs.ApplyT(func(kubeConfigs []containerservice.KubernetesClusterKubeConfig) (*string, error) {
 * 			return &kubeConfigs[0].ClientCertificate, nil
 * 		}).(pulumi.StringPtrOutput))
 * 		ctx.Export("kubeConfig", exampleKubernetesCluster.KubeConfigRaw)
 * 		return nil
 * 	})
 * }
 * ```
 * ```java
 * package generated_program;
 * import com.pulumi.Context;
 * import com.pulumi.Pulumi;
 * import com.pulumi.core.Output;
 * import com.pulumi.azure.core.ResourceGroup;
 * import com.pulumi.azure.core.ResourceGroupArgs;
 * import com.pulumi.azure.containerservice.KubernetesCluster;
 * import com.pulumi.azure.containerservice.KubernetesClusterArgs;
 * import com.pulumi.azure.containerservice.inputs.KubernetesClusterDefaultNodePoolArgs;
 * import com.pulumi.azure.containerservice.inputs.KubernetesClusterIdentityArgs;
 * import java.util.List;
 * import java.util.ArrayList;
 * import java.util.Map;
 * import java.io.File;
 * import java.nio.file.Files;
 * import java.nio.file.Paths;
 * public class App {
 *     public static void main(String[] args) {
 *         Pulumi.run(App::stack);
 *     }
 *     public static void stack(Context ctx) {
 *         var example = new ResourceGroup("example", ResourceGroupArgs.builder()
 *             .name("example-resources")
 *             .location("West Europe")
 *             .build());
 *         var exampleKubernetesCluster = new KubernetesCluster("exampleKubernetesCluster", KubernetesClusterArgs.builder()
 *             .name("example-aks1")
 *             .location(example.location())
 *             .resourceGroupName(example.name())
 *             .dnsPrefix("exampleaks1")
 *             .defaultNodePool(KubernetesClusterDefaultNodePoolArgs.builder()
 *                 .name("default")
 *                 .nodeCount(1)
 *                 .vmSize("Standard_D2_v2")
 *                 .build())
 *             .identity(KubernetesClusterIdentityArgs.builder()
 *                 .type("SystemAssigned")
 *                 .build())
 *             .tags(Map.of("Environment", "Production"))
 *             .build());
 *         ctx.export("clientCertificate", exampleKubernetesCluster.kubeConfigs().applyValue(kubeConfigs -> kubeConfigs[0].clientCertificate()));
 *         ctx.export("kubeConfig", exampleKubernetesCluster.kubeConfigRaw());
 *     }
 * }
 * ```
 * ```yaml
 * resources:
 *   example:
 *     type: azure:core:ResourceGroup
 *     properties:
 *       name: example-resources
 *       location: West Europe
 *   exampleKubernetesCluster:
 *     type: azure:containerservice:KubernetesCluster
 *     name: example
 *     properties:
 *       name: example-aks1
 *       location: ${example.location}
 *       resourceGroupName: ${example.name}
 *       dnsPrefix: exampleaks1
 *       defaultNodePool:
 *         name: default
 *         nodeCount: 1
 *         vmSize: Standard_D2_v2
 *       identity:
 *         type: SystemAssigned
 *       tags:
 *         Environment: Production
 * outputs:
 *   clientCertificate: ${exampleKubernetesCluster.kubeConfigs[0].clientCertificate}
 *   kubeConfig: ${exampleKubernetesCluster.kubeConfigRaw}
 * ```
 * 
 * ## Import
 * Managed Kubernetes Clusters can be imported using the `resource id`, e.g.
 * ```sh
 * $ pulumi import azure:containerservice/kubernetesCluster:KubernetesCluster cluster1 /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/group1/providers/Microsoft.ContainerService/managedClusters/cluster1
 * ```
 */
public class KubernetesCluster internal constructor(
    override val javaResource: com.pulumi.azure.containerservice.KubernetesCluster,
) : KotlinCustomResource(javaResource, KubernetesClusterMapper) {
    /**
     * A `aci_connector_linux` block as defined below. For more details, please visit [Create and configure an AKS cluster to use virtual nodes](https://docs.microsoft.com/azure/aks/virtual-nodes-portal).
     */
    public val aciConnectorLinux: Output?
        get() = javaResource.aciConnectorLinux().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 -> kubernetesClusterAciConnectorLinuxToKotlin(args0) })
            }).orElse(null)
        })

    /**
     * An `api_server_access_profile` block as defined below.
     */
    public val apiServerAccessProfile: Output
        get() = javaResource.apiServerAccessProfile().applyValue({ args0 ->
            args0.let({ args0 ->
                kubernetesClusterApiServerAccessProfileToKotlin(args0)
            })
        })

    @Deprecated(
        message = """
  This property has been renamed to `authorized_ip_ranges` within the `api_server_access_profile`
      block and will be removed in v4.0 of the provider
  """,
    )
    public val apiServerAuthorizedIpRanges: Output>
        get() = javaResource.apiServerAuthorizedIpRanges().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            })
        })

    /**
     * A `auto_scaler_profile` block as defined below.
     */
    public val autoScalerProfile: Output
        get() = javaResource.autoScalerProfile().applyValue({ args0 ->
            args0.let({ args0 ->
                kubernetesClusterAutoScalerProfileToKotlin(args0)
            })
        })

    /**
     * The upgrade channel for this Kubernetes Cluster. Possible values are `patch`, `rapid`, `node-image` and `stable`. Omitting this field sets this value to `none`.
     * !> **Note:** Cluster Auto-Upgrade will update the Kubernetes Cluster (and its Node Pools) to the latest GA version of Kubernetes automatically - please [see the Azure documentation for more information](https://docs.microsoft.com/azure/aks/upgrade-cluster#set-auto-upgrade-channel).
     * > **Note:** Cluster Auto-Upgrade only updates to GA versions of Kubernetes and will not update to Preview versions.
     */
    public val automaticChannelUpgrade: Output?
        get() = javaResource.automaticChannelUpgrade().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            }).orElse(null)
        })

    /**
     * A `azure_active_directory_role_based_access_control` block as defined below.
     */
    public val azureActiveDirectoryRoleBasedAccessControl:
        Output?
        get() = javaResource.azureActiveDirectoryRoleBasedAccessControl().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 ->
                    kubernetesClusterAzureActiveDirectoryRoleBasedAccessControlToKotlin(args0)
                })
            }).orElse(null)
        })

    /**
     * Should the Azure Policy Add-On be enabled? For more details please visit [Understand Azure Policy for Azure Kubernetes Service](https://docs.microsoft.com/en-ie/azure/governance/policy/concepts/rego-for-aks)
     */
    public val azurePolicyEnabled: Output?
        get() = javaResource.azurePolicyEnabled().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            }).orElse(null)
        })

    /**
     * A `confidential_computing` block as defined below. For more details please [the documentation](https://learn.microsoft.com/en-us/azure/confidential-computing/confidential-nodes-aks-overview)
     */
    public val confidentialComputing: Output?
        get() = javaResource.confidentialComputing().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 -> kubernetesClusterConfidentialComputingToKotlin(args0) })
            }).orElse(null)
        })

    /**
     * Should cost analysis be enabled for this Kubernetes Cluster? Defaults to `false`. The `sku_tier` must be set to `Standard` or `Premium` to enable this feature. Enabling this will add Kubernetes Namespace and Deployment details to the Cost Analysis views in the Azure portal.
     */
    public val costAnalysisEnabled: Output?
        get() = javaResource.costAnalysisEnabled().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            }).orElse(null)
        })

    /**
     * The current version running on the Azure Kubernetes Managed Cluster.
     */
    public val currentKubernetesVersion: Output
        get() = javaResource.currentKubernetesVersion().applyValue({ args0 -> args0 })

    /**
     * A list of up to 10 base64 encoded CAs that will be added to the trust store on nodes with the `custom_ca_trust_enabled` feature enabled.
     * > **Note:** Removing `custom_ca_trust_certificates_base64` after it has been set forces a new resource to be created.
     */
    public val customCaTrustCertificatesBase64s: Output>?
        get() = javaResource.customCaTrustCertificatesBase64s().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.map({ args0 -> args0 })
            }).orElse(null)
        })

    /**
     * A `default_node_pool` block as defined below.
     */
    public val defaultNodePool: Output
        get() = javaResource.defaultNodePool().applyValue({ args0 ->
            args0.let({ args0 ->
                kubernetesClusterDefaultNodePoolToKotlin(args0)
            })
        })

    /**
     * The ID of the Disk Encryption Set which should be used for the Nodes and Volumes. More information [can be found in the documentation](https://docs.microsoft.com/azure/aks/azure-disk-customer-managed-keys). Changing this forces a new resource to be created.
     */
    public val diskEncryptionSetId: Output?
        get() = javaResource.diskEncryptionSetId().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            }).orElse(null)
        })

    /**
     * DNS prefix specified when creating the managed cluster. Possible values must begin and end with a letter or number, contain only letters, numbers, and hyphens and be between 1 and 54 characters in length. Changing this forces a new resource to be created.
     */
    public val dnsPrefix: Output?
        get() = javaResource.dnsPrefix().applyValue({ args0 -> args0.map({ args0 -> args0 }).orElse(null) })

    /**
     * Specifies the DNS prefix to use with private clusters. Changing this forces a new resource to be created.
     * > **Note:** You must define either a `dns_prefix` or a `dns_prefix_private_cluster` field.
     * In addition, one of either `identity` or `service_principal` blocks must be specified.
     */
    public val dnsPrefixPrivateCluster: Output?
        get() = javaResource.dnsPrefixPrivateCluster().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            }).orElse(null)
        })

    /**
     * Specifies the Edge Zone within the Azure Region where this Managed Kubernetes Cluster should exist. Changing this forces a new resource to be created.
     */
    public val edgeZone: Output?
        get() = javaResource.edgeZone().applyValue({ args0 -> args0.map({ args0 -> args0 }).orElse(null) })

    @Deprecated(
        message = """
  The AKS API has removed support for this field on 2020-10-15 and it is no longer possible to
      configure Pod Security Policy. This property will be removed in v4.0 of the AzureRM provider.
  """,
    )
    public val enablePodSecurityPolicy: Output?
        get() = javaResource.enablePodSecurityPolicy().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            }).orElse(null)
        })

    /**
     * The FQDN of the Azure Kubernetes Managed Cluster.
     */
    public val fqdn: Output
        get() = javaResource.fqdn().applyValue({ args0 -> args0 })

    /**
     * Should HTTP Application Routing be enabled?
     * > **Note:** At this time HTTP Application Routing is not supported in Azure China or Azure US Government.
     */
    public val httpApplicationRoutingEnabled: Output?
        get() = javaResource.httpApplicationRoutingEnabled().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            }).orElse(null)
        })

    /**
     * The Zone Name of the HTTP Application Routing.
     */
    public val httpApplicationRoutingZoneName: Output
        get() = javaResource.httpApplicationRoutingZoneName().applyValue({ args0 -> args0 })

    /**
     * A `http_proxy_config` block as defined below.
     */
    public val httpProxyConfig: Output?
        get() = javaResource.httpProxyConfig().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 -> kubernetesClusterHttpProxyConfigToKotlin(args0) })
            }).orElse(null)
        })

    /**
     * An `identity` block as defined below. One of either `identity` or `service_principal` must be specified.
     * !> **Note:** A migration scenario from `service_principal` to `identity` is supported. When upgrading `service_principal` to `identity`, your cluster's control plane and addon pods will switch to use managed identity, but the kubelets will keep using your configured `service_principal` until you upgrade your Node Pool.
     */
    public val identity: Output?
        get() = javaResource.identity().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 ->
                    kubernetesClusterIdentityToKotlin(args0)
                })
            }).orElse(null)
        })

    /**
     * Specifies whether Image Cleaner is enabled.
     */
    public val imageCleanerEnabled: Output?
        get() = javaResource.imageCleanerEnabled().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            }).orElse(null)
        })

    /**
     * Specifies the interval in hours when images should be cleaned up. Defaults to `48`.
     */
    public val imageCleanerIntervalHours: Output?
        get() = javaResource.imageCleanerIntervalHours().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            }).orElse(null)
        })

    /**
     * A `ingress_application_gateway` block as defined below.
     * > **Note:** Since the Application Gateway is deployed inside a Virtual Network, users (and Service Principals) that are operating the Application Gateway must have the `Microsoft.Network/virtualNetworks/subnets/join/action` permission on the Virtual Network or Subnet. For more details, please visit [Virtual Network Permission](https://learn.microsoft.com/en-us/azure/application-gateway/configuration-infrastructure#virtual-network-permission).
     */
    public val ingressApplicationGateway: Output?
        get() = javaResource.ingressApplicationGateway().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 ->
                    kubernetesClusterIngressApplicationGatewayToKotlin(args0)
                })
            }).orElse(null)
        })

    /**
     * A `key_management_service` block as defined below. For more details, please visit [Key Management Service (KMS) etcd encryption to an AKS cluster](https://learn.microsoft.com/en-us/azure/aks/use-kms-etcd-encryption).
     */
    public val keyManagementService: Output?
        get() = javaResource.keyManagementService().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 -> kubernetesClusterKeyManagementServiceToKotlin(args0) })
            }).orElse(null)
        })

    /**
     * A `key_vault_secrets_provider` block as defined below. For more details, please visit [Azure Keyvault Secrets Provider for AKS](https://docs.microsoft.com/azure/aks/csi-secrets-store-driver).
     */
    public val keyVaultSecretsProvider: Output?
        get() = javaResource.keyVaultSecretsProvider().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 ->
                    kubernetesClusterKeyVaultSecretsProviderToKotlin(args0)
                })
            }).orElse(null)
        })

    /**
     * Raw Kubernetes config for the admin account to be used by [kubectl](https://kubernetes.io/docs/reference/kubectl/overview/) and other compatible tools. This is only available when Role Based Access Control with Azure Active Directory is enabled and local accounts enabled.
     */
    public val kubeAdminConfigRaw: Output
        get() = javaResource.kubeAdminConfigRaw().applyValue({ args0 -> args0 })

    /**
     * A `kube_admin_config` block as defined below. This is only available when Role Based Access Control with Azure Active Directory is enabled and local accounts enabled.
     */
    public val kubeAdminConfigs: Output>
        get() = javaResource.kubeAdminConfigs().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 -> kubernetesClusterKubeAdminConfigToKotlin(args0) })
            })
        })

    /**
     * Raw Kubernetes config to be used by [kubectl](https://kubernetes.io/docs/reference/kubectl/overview/) and other compatible tools.
     */
    public val kubeConfigRaw: Output
        get() = javaResource.kubeConfigRaw().applyValue({ args0 -> args0 })

    /**
     * A `kube_config` block as defined below.
     */
    public val kubeConfigs: Output>
        get() = javaResource.kubeConfigs().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 ->
                    kubernetesClusterKubeConfigToKotlin(args0)
                })
            })
        })

    /**
     * A `kubelet_identity` block as defined below.
     */
    public val kubeletIdentity: Output
        get() = javaResource.kubeletIdentity().applyValue({ args0 ->
            args0.let({ args0 ->
                kubernetesClusterKubeletIdentityToKotlin(args0)
            })
        })

    /**
     * Version of Kubernetes specified when creating the AKS managed cluster. If not specified, the latest recommended version will be used at provisioning time (but won't auto-upgrade). AKS does not require an exact patch version to be specified, minor version aliases such as `1.22` are also supported. - The minor version's latest GA patch is automatically chosen in that case. More details can be found in [the documentation](https://docs.microsoft.com/en-us/azure/aks/supported-kubernetes-versions?tabs=azure-cli#alias-minor-version).
     * > **Note:** Upgrading your cluster may take up to 10 minutes per node.
     */
    public val kubernetesVersion: Output
        get() = javaResource.kubernetesVersion().applyValue({ args0 -> args0 })

    /**
     * A `linux_profile` block as defined below.
     */
    public val linuxProfile: Output?
        get() = javaResource.linuxProfile().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 ->
                    kubernetesClusterLinuxProfileToKotlin(args0)
                })
            }).orElse(null)
        })

    /**
     * If `true` local accounts will be disabled. See [the documentation](https://docs.microsoft.com/azure/aks/managed-aad#disable-local-accounts) for more information.
     * > **Note:** If `local_account_disabled` is set to `true`, it is required to enable Kubernetes RBAC and AKS-managed Azure AD integration. See [the documentation](https://docs.microsoft.com/azure/aks/managed-aad#azure-ad-authentication-overview) for more information.
     */
    public val localAccountDisabled: Output?
        get() = javaResource.localAccountDisabled().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            }).orElse(null)
        })

    /**
     * The location where the Managed Kubernetes Cluster should be created. Changing this forces a new resource to be created.
     */
    public val location: Output
        get() = javaResource.location().applyValue({ args0 -> args0 })

    /**
     * A `maintenance_window` block as defined below.
     */
    public val maintenanceWindow: Output?
        get() = javaResource.maintenanceWindow().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 -> kubernetesClusterMaintenanceWindowToKotlin(args0) })
            }).orElse(null)
        })

    /**
     * A `maintenance_window_auto_upgrade` block as defined below.
     */
    public val maintenanceWindowAutoUpgrade: Output?
        get() = javaResource.maintenanceWindowAutoUpgrade().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 ->
                    kubernetesClusterMaintenanceWindowAutoUpgradeToKotlin(args0)
                })
            }).orElse(null)
        })

    /**
     * A `maintenance_window_node_os` block as defined below.
     */
    public val maintenanceWindowNodeOs: Output?
        get() = javaResource.maintenanceWindowNodeOs().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 ->
                    kubernetesClusterMaintenanceWindowNodeOsToKotlin(args0)
                })
            }).orElse(null)
        })

    /**
     * A `microsoft_defender` block as defined below.
     */
    public val microsoftDefender: Output?
        get() = javaResource.microsoftDefender().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 -> kubernetesClusterMicrosoftDefenderToKotlin(args0) })
            }).orElse(null)
        })

    /**
     * Specifies a Prometheus add-on profile for the Kubernetes Cluster. A `monitor_metrics` block as defined below.
     * > **Note:** If deploying Managed Prometheus, the `monitor_metrics` properties are required to configure the cluster for metrics collection. If no value is needed, set properties to `null`.
     */
    public val monitorMetrics: Output?
        get() = javaResource.monitorMetrics().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 -> kubernetesClusterMonitorMetricsToKotlin(args0) })
            }).orElse(null)
        })

    /**
     * The name of the Managed Kubernetes Cluster to create. Changing this forces a new resource to be created.
     */
    public val name: Output
        get() = javaResource.name().applyValue({ args0 -> args0 })

    /**
     * A `network_profile` block as defined below. Changing this forces a new resource to be created.
     * > **Note:** If `network_profile` is not defined, `kubenet` profile will be used by default.
     */
    public val networkProfile: Output
        get() = javaResource.networkProfile().applyValue({ args0 ->
            args0.let({ args0 ->
                kubernetesClusterNetworkProfileToKotlin(args0)
            })
        })

    /**
     * The upgrade channel for this Kubernetes Cluster Nodes' OS Image. Possible values are `Unmanaged`, `SecurityPatch`, `NodeImage` and `None`.
     * > **Note:** `node_os_channel_upgrade` must be set to `NodeImage` if `automatic_channel_upgrade` has been set to `node-image`
     */
    public val nodeOsChannelUpgrade: Output?
        get() = javaResource.nodeOsChannelUpgrade().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            }).orElse(null)
        })

    /**
     * The name of the Resource Group where the Kubernetes Nodes should exist. Changing this forces a new resource to be created.
     * > **Note:** Azure requires that a new, non-existent Resource Group is used, as otherwise, the provisioning of the Kubernetes Service will fail.
     */
    public val nodeResourceGroup: Output
        get() = javaResource.nodeResourceGroup().applyValue({ args0 -> args0 })

    /**
     * The ID of the Resource Group containing the resources for this Managed Kubernetes Cluster.
     */
    public val nodeResourceGroupId: Output
        get() = javaResource.nodeResourceGroupId().applyValue({ args0 -> args0 })

    /**
     * Enable or Disable the [OIDC issuer URL](https://learn.microsoft.com/en-gb/azure/aks/use-oidc-issuer)
     */
    public val oidcIssuerEnabled: Output?
        get() = javaResource.oidcIssuerEnabled().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            }).orElse(null)
        })

    /**
     * The OIDC issuer URL that is associated with the cluster.
     */
    public val oidcIssuerUrl: Output
        get() = javaResource.oidcIssuerUrl().applyValue({ args0 -> args0 })

    /**
     * A `oms_agent` block as defined below.
     */
    public val omsAgent: Output?
        get() = javaResource.omsAgent().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 ->
                    kubernetesClusterOmsAgentToKotlin(args0)
                })
            }).orElse(null)
        })

    /**
     * Is Open Service Mesh enabled? For more details, please visit [Open Service Mesh for AKS](https://docs.microsoft.com/azure/aks/open-service-mesh-about).
     */
    public val openServiceMeshEnabled: Output?
        get() = javaResource.openServiceMeshEnabled().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            }).orElse(null)
        })

    /**
     * The FQDN for the Azure Portal resources when private link has been enabled, which is only resolvable inside the Virtual Network used by the Kubernetes Cluster.
     */
    public val portalFqdn: Output
        get() = javaResource.portalFqdn().applyValue({ args0 -> args0 })

    /**
     * Should this Kubernetes Cluster have its API server only exposed on internal IP addresses? This provides a Private IP Address for the Kubernetes API on the Virtual Network where the Kubernetes Cluster is located. Defaults to `false`. Changing this forces a new resource to be created.
     */
    public val privateClusterEnabled: Output?
        get() = javaResource.privateClusterEnabled().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            }).orElse(null)
        })

    /**
     * Specifies whether a Public FQDN for this Private Cluster should be added. Defaults to `false`.
     * > **Note:** If you use BYO DNS Zone, the AKS cluster should either use a User Assigned Identity or a service principal (which is deprecated) with the `Private DNS Zone Contributor` role and access to this Private DNS Zone. If `UserAssigned` identity is used - to prevent improper resource order destruction - the cluster should depend on the role assignment, like in this example:
     * 
     * ```typescript
     * import * as pulumi from "@pulumi/pulumi";
     * import * as azure from "@pulumi/azure";
     * const example = new azure.core.ResourceGroup("example", {
     *     name: "example",
     *     location: "West Europe",
     * });
     * const exampleZone = new azure.privatedns.Zone("example", {
     *     name: "privatelink.eastus2.azmk8s.io",
     *     resourceGroupName: example.name,
     * });
     * const exampleUserAssignedIdentity = new azure.authorization.UserAssignedIdentity("example", {
     *     name: "aks-example-identity",
     *     resourceGroupName: example.name,
     *     location: example.location,
     * });
     * const exampleAssignment = new azure.authorization.Assignment("example", {
     *     scope: exampleZone.id,
     *     roleDefinitionName: "Private DNS Zone Contributor",
     *     principalId: exampleUserAssignedIdentity.principalId,
     * });
     * const exampleKubernetesCluster = new azure.containerservice.KubernetesCluster("example", {
     *     name: "aksexamplewithprivatednszone1",
     *     location: example.location,
     *     resourceGroupName: example.name,
     *     dnsPrefix: "aksexamplednsprefix1",
     *     privateClusterEnabled: true,
     *     privateDnsZoneId: exampleZone.id,
     * }, {
     *     dependsOn: [exampleAssignment],
     * });
     * ```
     * ```python
     * import pulumi
     * import pulumi_azure as azure
     * example = azure.core.ResourceGroup("example",
     *     name="example",
     *     location="West Europe")
     * example_zone = azure.privatedns.Zone("example",
     *     name="privatelink.eastus2.azmk8s.io",
     *     resource_group_name=example.name)
     * example_user_assigned_identity = azure.authorization.UserAssignedIdentity("example",
     *     name="aks-example-identity",
     *     resource_group_name=example.name,
     *     location=example.location)
     * example_assignment = azure.authorization.Assignment("example",
     *     scope=example_zone.id,
     *     role_definition_name="Private DNS Zone Contributor",
     *     principal_id=example_user_assigned_identity.principal_id)
     * example_kubernetes_cluster = azure.containerservice.KubernetesCluster("example",
     *     name="aksexamplewithprivatednszone1",
     *     location=example.location,
     *     resource_group_name=example.name,
     *     dns_prefix="aksexamplednsprefix1",
     *     private_cluster_enabled=True,
     *     private_dns_zone_id=example_zone.id,
     *     opts = pulumi.ResourceOptions(depends_on=[example_assignment]))
     * ```
     * ```csharp
     * using System.Collections.Generic;
     * using System.Linq;
     * using Pulumi;
     * using Azure = Pulumi.Azure;
     * return await Deployment.RunAsync(() =>
     * {
     *     var example = new Azure.Core.ResourceGroup("example", new()
     *     {
     *         Name = "example",
     *         Location = "West Europe",
     *     });
     *     var exampleZone = new Azure.PrivateDns.Zone("example", new()
     *     {
     *         Name = "privatelink.eastus2.azmk8s.io",
     *         ResourceGroupName = example.Name,
     *     });
     *     var exampleUserAssignedIdentity = new Azure.Authorization.UserAssignedIdentity("example", new()
     *     {
     *         Name = "aks-example-identity",
     *         ResourceGroupName = example.Name,
     *         Location = example.Location,
     *     });
     *     var exampleAssignment = new Azure.Authorization.Assignment("example", new()
     *     {
     *         Scope = exampleZone.Id,
     *         RoleDefinitionName = "Private DNS Zone Contributor",
     *         PrincipalId = exampleUserAssignedIdentity.PrincipalId,
     *     });
     *     var exampleKubernetesCluster = new Azure.ContainerService.KubernetesCluster("example", new()
     *     {
     *         Name = "aksexamplewithprivatednszone1",
     *         Location = example.Location,
     *         ResourceGroupName = example.Name,
     *         DnsPrefix = "aksexamplednsprefix1",
     *         PrivateClusterEnabled = true,
     *         PrivateDnsZoneId = exampleZone.Id,
     *     }, new CustomResourceOptions
     *     {
     *         DependsOn =
     *         {
     *             exampleAssignment,
     *         },
     *     });
     * });
     * ```
     * ```go
     * package main
     * import (
     * 	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/authorization"
     * 	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/containerservice"
     * 	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/core"
     * 	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/privatedns"
     * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
     * )
     * func main() {
     * 	pulumi.Run(func(ctx *pulumi.Context) error {
     * 		example, err := core.NewResourceGroup(ctx, "example", &core.ResourceGroupArgs{
     * 			Name:     pulumi.String("example"),
     * 			Location: pulumi.String("West Europe"),
     * 		})
     * 		if err != nil {
     * 			return err
     * 		}
     * 		exampleZone, err := privatedns.NewZone(ctx, "example", &privatedns.ZoneArgs{
     * 			Name:              pulumi.String("privatelink.eastus2.azmk8s.io"),
     * 			ResourceGroupName: example.Name,
     * 		})
     * 		if err != nil {
     * 			return err
     * 		}
     * 		exampleUserAssignedIdentity, err := authorization.NewUserAssignedIdentity(ctx, "example", &authorization.UserAssignedIdentityArgs{
     * 			Name:              pulumi.String("aks-example-identity"),
     * 			ResourceGroupName: example.Name,
     * 			Location:          example.Location,
     * 		})
     * 		if err != nil {
     * 			return err
     * 		}
     * 		exampleAssignment, err := authorization.NewAssignment(ctx, "example", &authorization.AssignmentArgs{
     * 			Scope:              exampleZone.ID(),
     * 			RoleDefinitionName: pulumi.String("Private DNS Zone Contributor"),
     * 			PrincipalId:        exampleUserAssignedIdentity.PrincipalId,
     * 		})
     * 		if err != nil {
     * 			return err
     * 		}
     * 		_, err = containerservice.NewKubernetesCluster(ctx, "example", &containerservice.KubernetesClusterArgs{
     * 			Name:                  pulumi.String("aksexamplewithprivatednszone1"),
     * 			Location:              example.Location,
     * 			ResourceGroupName:     example.Name,
     * 			DnsPrefix:             pulumi.String("aksexamplednsprefix1"),
     * 			PrivateClusterEnabled: pulumi.Bool(true),
     * 			PrivateDnsZoneId:      exampleZone.ID(),
     * 		}, pulumi.DependsOn([]pulumi.Resource{
     * 			exampleAssignment,
     * 		}))
     * 		if err != nil {
     * 			return err
     * 		}
     * 		return nil
     * 	})
     * }
     * ```
     * ```java
     * package generated_program;
     * import com.pulumi.Context;
     * import com.pulumi.Pulumi;
     * import com.pulumi.core.Output;
     * import com.pulumi.azure.core.ResourceGroup;
     * import com.pulumi.azure.core.ResourceGroupArgs;
     * import com.pulumi.azure.privatedns.Zone;
     * import com.pulumi.azure.privatedns.ZoneArgs;
     * import com.pulumi.azure.authorization.UserAssignedIdentity;
     * import com.pulumi.azure.authorization.UserAssignedIdentityArgs;
     * import com.pulumi.azure.authorization.Assignment;
     * import com.pulumi.azure.authorization.AssignmentArgs;
     * import com.pulumi.azure.containerservice.KubernetesCluster;
     * import com.pulumi.azure.containerservice.KubernetesClusterArgs;
     * import com.pulumi.resources.CustomResourceOptions;
     * import java.util.List;
     * import java.util.ArrayList;
     * import java.util.Map;
     * import java.io.File;
     * import java.nio.file.Files;
     * import java.nio.file.Paths;
     * public class App {
     *     public static void main(String[] args) {
     *         Pulumi.run(App::stack);
     *     }
     *     public static void stack(Context ctx) {
     *         var example = new ResourceGroup("example", ResourceGroupArgs.builder()
     *             .name("example")
     *             .location("West Europe")
     *             .build());
     *         var exampleZone = new Zone("exampleZone", ZoneArgs.builder()
     *             .name("privatelink.eastus2.azmk8s.io")
     *             .resourceGroupName(example.name())
     *             .build());
     *         var exampleUserAssignedIdentity = new UserAssignedIdentity("exampleUserAssignedIdentity", UserAssignedIdentityArgs.builder()
     *             .name("aks-example-identity")
     *             .resourceGroupName(example.name())
     *             .location(example.location())
     *             .build());
     *         var exampleAssignment = new Assignment("exampleAssignment", AssignmentArgs.builder()
     *             .scope(exampleZone.id())
     *             .roleDefinitionName("Private DNS Zone Contributor")
     *             .principalId(exampleUserAssignedIdentity.principalId())
     *             .build());
     *         var exampleKubernetesCluster = new KubernetesCluster("exampleKubernetesCluster", KubernetesClusterArgs.builder()
     *             .name("aksexamplewithprivatednszone1")
     *             .location(example.location())
     *             .resourceGroupName(example.name())
     *             .dnsPrefix("aksexamplednsprefix1")
     *             .privateClusterEnabled(true)
     *             .privateDnsZoneId(exampleZone.id())
     *             .build(), CustomResourceOptions.builder()
     *                 .dependsOn(exampleAssignment)
     *                 .build());
     *     }
     * }
     * ```
     * ```yaml
     * resources:
     *   example:
     *     type: azure:core:ResourceGroup
     *     properties:
     *       name: example
     *       location: West Europe
     *   exampleZone:
     *     type: azure:privatedns:Zone
     *     name: example
     *     properties:
     *       name: privatelink.eastus2.azmk8s.io
     *       resourceGroupName: ${example.name}
     *   exampleUserAssignedIdentity:
     *     type: azure:authorization:UserAssignedIdentity
     *     name: example
     *     properties:
     *       name: aks-example-identity
     *       resourceGroupName: ${example.name}
     *       location: ${example.location}
     *   exampleAssignment:
     *     type: azure:authorization:Assignment
     *     name: example
     *     properties:
     *       scope: ${exampleZone.id}
     *       roleDefinitionName: Private DNS Zone Contributor
     *       principalId: ${exampleUserAssignedIdentity.principalId}
     *   exampleKubernetesCluster:
     *     type: azure:containerservice:KubernetesCluster
     *     name: example
     *     properties:
     *       name: aksexamplewithprivatednszone1
     *       location: ${example.location}
     *       resourceGroupName: ${example.name}
     *       dnsPrefix: aksexamplednsprefix1
     *       privateClusterEnabled: true
     *       privateDnsZoneId: ${exampleZone.id}
     *     options:
     *       dependson:
     *         - ${exampleAssignment}
     * ```
     * 
     */
    public val privateClusterPublicFqdnEnabled: Output?
        get() = javaResource.privateClusterPublicFqdnEnabled().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            }).orElse(null)
        })

    /**
     * Either the ID of Private DNS Zone which should be delegated to this Cluster, `System` to have AKS manage this or `None`. In case of `None` you will need to bring your own DNS server and set up resolving, otherwise, the cluster will have issues after provisioning. Changing this forces a new resource to be created.
     */
    public val privateDnsZoneId: Output
        get() = javaResource.privateDnsZoneId().applyValue({ args0 -> args0 })

    /**
     * The FQDN for the Kubernetes Cluster when private link has been enabled, which is only resolvable inside the Virtual Network used by the Kubernetes Cluster.
     */
    public val privateFqdn: Output
        get() = javaResource.privateFqdn().applyValue({ args0 -> args0 })

    @Deprecated(
        message = """
  `public_network_access_enabled` is currently not functional and is not be passed to the API, this
      property will be removed in v4.0 of the AzureRM provider.
  """,
    )
    public val publicNetworkAccessEnabled: Output?
        get() = javaResource.publicNetworkAccessEnabled().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            }).orElse(null)
        })

    /**
     * Specifies the Resource Group where the Managed Kubernetes Cluster should exist. Changing this forces a new resource to be created.
     */
    public val resourceGroupName: Output
        get() = javaResource.resourceGroupName().applyValue({ args0 -> args0 })

    /**
     * Whether Role Based Access Control for the Kubernetes Cluster should be enabled. Defaults to `true`. Changing this forces a new resource to be created.
     */
    public val roleBasedAccessControlEnabled: Output?
        get() = javaResource.roleBasedAccessControlEnabled().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            }).orElse(null)
        })

    /**
     * Whether to enable run command for the cluster or not. Defaults to `true`.
     */
    public val runCommandEnabled: Output?
        get() = javaResource.runCommandEnabled().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            }).orElse(null)
        })

    /**
     * A `service_mesh_profile` block as defined below.
     */
    public val serviceMeshProfile: Output?
        get() = javaResource.serviceMeshProfile().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 -> kubernetesClusterServiceMeshProfileToKotlin(args0) })
            }).orElse(null)
        })

    /**
     * A `service_principal` block as documented below. One of either `identity` or `service_principal` must be specified.
     * !> **Note:** A migration scenario from `service_principal` to `identity` is supported. When upgrading `service_principal` to `identity`, your cluster's control plane and addon pods will switch to use managed identity, but the kubelets will keep using your configured `service_principal` until you upgrade your Node Pool.
     */
    public val servicePrincipal: Output?
        get() = javaResource.servicePrincipal().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 -> kubernetesClusterServicePrincipalToKotlin(args0) })
            }).orElse(null)
        })

    /**
     * The SKU Tier that should be used for this Kubernetes Cluster. Possible values are `Free`, `Standard` (which includes the Uptime SLA) and `Premium`. Defaults to `Free`.
     * > **Note:** Whilst the AKS API previously supported the `Paid` SKU - the AKS API introduced a breaking change in API Version `2023-02-01` (used in v3.51.0 and later) where the value `Paid` must now be set to `Standard`.
     */
    public val skuTier: Output?
        get() = javaResource.skuTier().applyValue({ args0 -> args0.map({ args0 -> args0 }).orElse(null) })

    /**
     * A `storage_profile` block as defined below.
     */
    public val storageProfile: Output?
        get() = javaResource.storageProfile().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 -> kubernetesClusterStorageProfileToKotlin(args0) })
            }).orElse(null)
        })

    /**
     * Specifies the support plan which should be used for this Kubernetes Cluster. Possible values are `KubernetesOfficial` and `AKSLongTermSupport`. Defaults to `KubernetesOfficial`.
     */
    public val supportPlan: Output?
        get() = javaResource.supportPlan().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            }).orElse(null)
        })

    /**
     * A mapping of tags to assign to the resource.
     */
    public val tags: Output>?
        get() = javaResource.tags().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.map({ args0 ->
                    args0.key.to(args0.value)
                }).toMap()
            }).orElse(null)
        })

    /**
     * A `web_app_routing` block as defined below.
     */
    public val webAppRouting: Output?
        get() = javaResource.webAppRouting().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 -> kubernetesClusterWebAppRoutingToKotlin(args0) })
            }).orElse(null)
        })

    /**
     * A `windows_profile` block as defined below.
     */
    public val windowsProfile: Output
        get() = javaResource.windowsProfile().applyValue({ args0 ->
            args0.let({ args0 ->
                kubernetesClusterWindowsProfileToKotlin(args0)
            })
        })

    /**
     * A `workload_autoscaler_profile` block defined below.
     */
    public val workloadAutoscalerProfile: Output?
        get() = javaResource.workloadAutoscalerProfile().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 ->
                    kubernetesClusterWorkloadAutoscalerProfileToKotlin(args0)
                })
            }).orElse(null)
        })

    /**
     * Specifies whether Azure AD Workload Identity should be enabled for the Cluster. Defaults to `false`.
     * > **Note:** To enable Azure AD Workload Identity `oidc_issuer_enabled` must be set to `true`.
     * > **Note:** Enabling this option will allocate Workload Identity resources to the `kube-system` namespace in Kubernetes. If you wish to customize the deployment of Workload Identity, you can refer to [the documentation on Azure AD Workload Identity.](https://azure.github.io/azure-workload-identity/docs/installation/mutating-admission-webhook.html) The documentation provides guidance on how to install the mutating admission webhook, which allows for the customization of Workload Identity deployment.
     */
    public val workloadIdentityEnabled: Output?
        get() = javaResource.workloadIdentityEnabled().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            }).orElse(null)
        })
}

public object KubernetesClusterMapper : ResourceMapper {
    override fun supportsMappingOfType(javaResource: Resource): Boolean =
        com.pulumi.azure.containerservice.KubernetesCluster::class == javaResource::class

    override fun map(javaResource: Resource): KubernetesCluster = KubernetesCluster(
        javaResource as
            com.pulumi.azure.containerservice.KubernetesCluster,
    )
}

/**
 * @see [KubernetesCluster].
 * @param name The _unique_ name of the resulting resource.
 * @param block Builder for [KubernetesCluster].
 */
public suspend fun kubernetesCluster(
    name: String,
    block: suspend KubernetesClusterResourceBuilder.() -> Unit,
): KubernetesCluster {
    val builder = KubernetesClusterResourceBuilder()
    builder.name(name)
    block(builder)
    return builder.build()
}

/**
 * @see [KubernetesCluster].
 * @param name The _unique_ name of the resulting resource.
 */
public fun kubernetesCluster(name: String): KubernetesCluster {
    val builder = KubernetesClusterResourceBuilder()
    builder.name(name)
    return builder.build()
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy