"use strict";
// *** WARNING: this file was generated by pulumi-language-nodejs. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
    if (k2 === undefined) k2 = k;
    var desc = Object.getOwnPropertyDescriptor(m, k);
    if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
      desc = { enumerable: true, get: function() { return m[k]; } };
    }
    Object.defineProperty(o, k2, desc);
}) : (function(o, m, k, k2) {
    if (k2 === undefined) k2 = k;
    o[k2] = m[k];
}));
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
    Object.defineProperty(o, "default", { enumerable: true, value: v });
}) : function(o, v) {
    o["default"] = v;
});
var __importStar = (this && this.__importStar) || function (mod) {
    if (mod && mod.__esModule) return mod;
    var result = {};
    if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
    __setModuleDefault(result, mod);
    return result;
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.KubernetesCluster = void 0;
const pulumi = __importStar(require("@pulumi/pulumi"));
const utilities = __importStar(require("../utilities"));
/**
 * Manages a Managed Kubernetes Cluster (also known as AKS / Azure Kubernetes Service)
 *
 * > **Note:** Due to the fast-moving nature of AKS, we recommend using the latest version of the Azure Provider when using AKS.
 *
 * ## 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;
 * ```
 *
 * ## API Providers
 *
 * <!-- This section is generated, changes will be overwritten -->
 * This resource uses the following Azure API Providers:
 *
 * * `Microsoft.ContainerService` - 2025-10-01
 *
 * ## 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
 * ```
 */
class KubernetesCluster extends pulumi.CustomResource {
    /**
     * Get an existing KubernetesCluster resource's state with the given name, ID, and optional extra
     * properties used to qualify the lookup.
     *
     * @param name The _unique_ name of the resulting resource.
     * @param id The _unique_ provider ID of the resource to lookup.
     * @param state Any extra arguments used during the lookup.
     * @param opts Optional settings to control the behavior of the CustomResource.
     */
    static get(name, id, state, opts) {
        return new KubernetesCluster(name, state, { ...opts, id: id });
    }
    /** @internal */
    static __pulumiType = 'azure:containerservice/kubernetesCluster:KubernetesCluster';
    /**
     * Returns true if the given object is an instance of KubernetesCluster.  This is designed to work even
     * when multiple copies of the Pulumi SDK have been loaded into the same process.
     */
    static isInstance(obj) {
        if (obj === undefined || obj === null) {
            return false;
        }
        return obj['__pulumiType'] === KubernetesCluster.__pulumiType;
    }
    constructor(name, argsOrState, opts) {
        let resourceInputs = {};
        opts = opts || {};
        if (opts.id) {
            const state = argsOrState;
            resourceInputs["aciConnectorLinux"] = state?.aciConnectorLinux;
            resourceInputs["aiToolchainOperatorEnabled"] = state?.aiToolchainOperatorEnabled;
            resourceInputs["apiServerAccessProfile"] = state?.apiServerAccessProfile;
            resourceInputs["autoScalerProfile"] = state?.autoScalerProfile;
            resourceInputs["automaticUpgradeChannel"] = state?.automaticUpgradeChannel;
            resourceInputs["azureActiveDirectoryRoleBasedAccessControl"] = state?.azureActiveDirectoryRoleBasedAccessControl;
            resourceInputs["azurePolicyEnabled"] = state?.azurePolicyEnabled;
            resourceInputs["bootstrapProfile"] = state?.bootstrapProfile;
            resourceInputs["confidentialComputing"] = state?.confidentialComputing;
            resourceInputs["costAnalysisEnabled"] = state?.costAnalysisEnabled;
            resourceInputs["currentKubernetesVersion"] = state?.currentKubernetesVersion;
            resourceInputs["customCaTrustCertificatesBase64s"] = state?.customCaTrustCertificatesBase64s;
            resourceInputs["defaultNodePool"] = state?.defaultNodePool;
            resourceInputs["diskEncryptionSetId"] = state?.diskEncryptionSetId;
            resourceInputs["dnsPrefix"] = state?.dnsPrefix;
            resourceInputs["dnsPrefixPrivateCluster"] = state?.dnsPrefixPrivateCluster;
            resourceInputs["edgeZone"] = state?.edgeZone;
            resourceInputs["fqdn"] = state?.fqdn;
            resourceInputs["httpApplicationRoutingEnabled"] = state?.httpApplicationRoutingEnabled;
            resourceInputs["httpApplicationRoutingZoneName"] = state?.httpApplicationRoutingZoneName;
            resourceInputs["httpProxyConfig"] = state?.httpProxyConfig;
            resourceInputs["identity"] = state?.identity;
            resourceInputs["imageCleanerEnabled"] = state?.imageCleanerEnabled;
            resourceInputs["imageCleanerIntervalHours"] = state?.imageCleanerIntervalHours;
            resourceInputs["ingressApplicationGateway"] = state?.ingressApplicationGateway;
            resourceInputs["keyManagementService"] = state?.keyManagementService;
            resourceInputs["keyVaultSecretsProvider"] = state?.keyVaultSecretsProvider;
            resourceInputs["kubeAdminConfigRaw"] = state?.kubeAdminConfigRaw;
            resourceInputs["kubeAdminConfigs"] = state?.kubeAdminConfigs;
            resourceInputs["kubeConfigRaw"] = state?.kubeConfigRaw;
            resourceInputs["kubeConfigs"] = state?.kubeConfigs;
            resourceInputs["kubeletIdentity"] = state?.kubeletIdentity;
            resourceInputs["kubernetesVersion"] = state?.kubernetesVersion;
            resourceInputs["linuxProfile"] = state?.linuxProfile;
            resourceInputs["localAccountDisabled"] = state?.localAccountDisabled;
            resourceInputs["location"] = state?.location;
            resourceInputs["maintenanceWindow"] = state?.maintenanceWindow;
            resourceInputs["maintenanceWindowAutoUpgrade"] = state?.maintenanceWindowAutoUpgrade;
            resourceInputs["maintenanceWindowNodeOs"] = state?.maintenanceWindowNodeOs;
            resourceInputs["microsoftDefender"] = state?.microsoftDefender;
            resourceInputs["monitorMetrics"] = state?.monitorMetrics;
            resourceInputs["name"] = state?.name;
            resourceInputs["networkProfile"] = state?.networkProfile;
            resourceInputs["nodeOsUpgradeChannel"] = state?.nodeOsUpgradeChannel;
            resourceInputs["nodeProvisioningProfile"] = state?.nodeProvisioningProfile;
            resourceInputs["nodeResourceGroup"] = state?.nodeResourceGroup;
            resourceInputs["nodeResourceGroupId"] = state?.nodeResourceGroupId;
            resourceInputs["oidcIssuerEnabled"] = state?.oidcIssuerEnabled;
            resourceInputs["oidcIssuerUrl"] = state?.oidcIssuerUrl;
            resourceInputs["omsAgent"] = state?.omsAgent;
            resourceInputs["openServiceMeshEnabled"] = state?.openServiceMeshEnabled;
            resourceInputs["portalFqdn"] = state?.portalFqdn;
            resourceInputs["privateClusterEnabled"] = state?.privateClusterEnabled;
            resourceInputs["privateClusterPublicFqdnEnabled"] = state?.privateClusterPublicFqdnEnabled;
            resourceInputs["privateDnsZoneId"] = state?.privateDnsZoneId;
            resourceInputs["privateFqdn"] = state?.privateFqdn;
            resourceInputs["resourceGroupName"] = state?.resourceGroupName;
            resourceInputs["roleBasedAccessControlEnabled"] = state?.roleBasedAccessControlEnabled;
            resourceInputs["runCommandEnabled"] = state?.runCommandEnabled;
            resourceInputs["serviceMeshProfile"] = state?.serviceMeshProfile;
            resourceInputs["servicePrincipal"] = state?.servicePrincipal;
            resourceInputs["skuTier"] = state?.skuTier;
            resourceInputs["storageProfile"] = state?.storageProfile;
            resourceInputs["supportPlan"] = state?.supportPlan;
            resourceInputs["tags"] = state?.tags;
            resourceInputs["upgradeOverride"] = state?.upgradeOverride;
            resourceInputs["webAppRouting"] = state?.webAppRouting;
            resourceInputs["windowsProfile"] = state?.windowsProfile;
            resourceInputs["workloadAutoscalerProfile"] = state?.workloadAutoscalerProfile;
            resourceInputs["workloadIdentityEnabled"] = state?.workloadIdentityEnabled;
        }
        else {
            const args = argsOrState;
            if (args?.defaultNodePool === undefined && !opts.urn) {
                throw new Error("Missing required property 'defaultNodePool'");
            }
            if (args?.resourceGroupName === undefined && !opts.urn) {
                throw new Error("Missing required property 'resourceGroupName'");
            }
            resourceInputs["aciConnectorLinux"] = args?.aciConnectorLinux;
            resourceInputs["aiToolchainOperatorEnabled"] = args?.aiToolchainOperatorEnabled;
            resourceInputs["apiServerAccessProfile"] = args?.apiServerAccessProfile;
            resourceInputs["autoScalerProfile"] = args?.autoScalerProfile;
            resourceInputs["automaticUpgradeChannel"] = args?.automaticUpgradeChannel;
            resourceInputs["azureActiveDirectoryRoleBasedAccessControl"] = args?.azureActiveDirectoryRoleBasedAccessControl;
            resourceInputs["azurePolicyEnabled"] = args?.azurePolicyEnabled;
            resourceInputs["bootstrapProfile"] = args?.bootstrapProfile;
            resourceInputs["confidentialComputing"] = args?.confidentialComputing;
            resourceInputs["costAnalysisEnabled"] = args?.costAnalysisEnabled;
            resourceInputs["customCaTrustCertificatesBase64s"] = args?.customCaTrustCertificatesBase64s;
            resourceInputs["defaultNodePool"] = args?.defaultNodePool;
            resourceInputs["diskEncryptionSetId"] = args?.diskEncryptionSetId;
            resourceInputs["dnsPrefix"] = args?.dnsPrefix;
            resourceInputs["dnsPrefixPrivateCluster"] = args?.dnsPrefixPrivateCluster;
            resourceInputs["edgeZone"] = args?.edgeZone;
            resourceInputs["httpApplicationRoutingEnabled"] = args?.httpApplicationRoutingEnabled;
            resourceInputs["httpProxyConfig"] = args?.httpProxyConfig;
            resourceInputs["identity"] = args?.identity;
            resourceInputs["imageCleanerEnabled"] = args?.imageCleanerEnabled;
            resourceInputs["imageCleanerIntervalHours"] = args?.imageCleanerIntervalHours;
            resourceInputs["ingressApplicationGateway"] = args?.ingressApplicationGateway;
            resourceInputs["keyManagementService"] = args?.keyManagementService;
            resourceInputs["keyVaultSecretsProvider"] = args?.keyVaultSecretsProvider;
            resourceInputs["kubeletIdentity"] = args?.kubeletIdentity;
            resourceInputs["kubernetesVersion"] = args?.kubernetesVersion;
            resourceInputs["linuxProfile"] = args?.linuxProfile;
            resourceInputs["localAccountDisabled"] = args?.localAccountDisabled;
            resourceInputs["location"] = args?.location;
            resourceInputs["maintenanceWindow"] = args?.maintenanceWindow;
            resourceInputs["maintenanceWindowAutoUpgrade"] = args?.maintenanceWindowAutoUpgrade;
            resourceInputs["maintenanceWindowNodeOs"] = args?.maintenanceWindowNodeOs;
            resourceInputs["microsoftDefender"] = args?.microsoftDefender;
            resourceInputs["monitorMetrics"] = args?.monitorMetrics;
            resourceInputs["name"] = args?.name;
            resourceInputs["networkProfile"] = args?.networkProfile;
            resourceInputs["nodeOsUpgradeChannel"] = args?.nodeOsUpgradeChannel;
            resourceInputs["nodeProvisioningProfile"] = args?.nodeProvisioningProfile;
            resourceInputs["nodeResourceGroup"] = args?.nodeResourceGroup;
            resourceInputs["oidcIssuerEnabled"] = args?.oidcIssuerEnabled;
            resourceInputs["omsAgent"] = args?.omsAgent;
            resourceInputs["openServiceMeshEnabled"] = args?.openServiceMeshEnabled;
            resourceInputs["privateClusterEnabled"] = args?.privateClusterEnabled;
            resourceInputs["privateClusterPublicFqdnEnabled"] = args?.privateClusterPublicFqdnEnabled;
            resourceInputs["privateDnsZoneId"] = args?.privateDnsZoneId;
            resourceInputs["resourceGroupName"] = args?.resourceGroupName;
            resourceInputs["roleBasedAccessControlEnabled"] = args?.roleBasedAccessControlEnabled;
            resourceInputs["runCommandEnabled"] = args?.runCommandEnabled;
            resourceInputs["serviceMeshProfile"] = args?.serviceMeshProfile;
            resourceInputs["servicePrincipal"] = args?.servicePrincipal;
            resourceInputs["skuTier"] = args?.skuTier;
            resourceInputs["storageProfile"] = args?.storageProfile;
            resourceInputs["supportPlan"] = args?.supportPlan;
            resourceInputs["tags"] = args?.tags;
            resourceInputs["upgradeOverride"] = args?.upgradeOverride;
            resourceInputs["webAppRouting"] = args?.webAppRouting;
            resourceInputs["windowsProfile"] = args?.windowsProfile;
            resourceInputs["workloadAutoscalerProfile"] = args?.workloadAutoscalerProfile;
            resourceInputs["workloadIdentityEnabled"] = args?.workloadIdentityEnabled;
            resourceInputs["currentKubernetesVersion"] = undefined /*out*/;
            resourceInputs["fqdn"] = undefined /*out*/;
            resourceInputs["httpApplicationRoutingZoneName"] = undefined /*out*/;
            resourceInputs["kubeAdminConfigRaw"] = undefined /*out*/;
            resourceInputs["kubeAdminConfigs"] = undefined /*out*/;
            resourceInputs["kubeConfigRaw"] = undefined /*out*/;
            resourceInputs["kubeConfigs"] = undefined /*out*/;
            resourceInputs["nodeResourceGroupId"] = undefined /*out*/;
            resourceInputs["oidcIssuerUrl"] = undefined /*out*/;
            resourceInputs["portalFqdn"] = undefined /*out*/;
            resourceInputs["privateFqdn"] = undefined /*out*/;
        }
        opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
        const secretOpts = { additionalSecretOutputs: ["kubeAdminConfigRaw", "kubeAdminConfigs", "kubeConfigRaw", "kubeConfigs"] };
        opts = pulumi.mergeOptions(opts, secretOpts);
        super(KubernetesCluster.__pulumiType, name, resourceInputs, opts);
    }
}
exports.KubernetesCluster = KubernetesCluster;
//# sourceMappingURL=kubernetesCluster.js.map