"use strict";
// *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
Object.defineProperty(exports, "__esModule", { value: true });
exports.DefaultNodePoolBatchAttach = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("../utilities");
/**
 * Provides a resource to manage vke default node pool batch attach
 * ## Example Usage
 *
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as volcengine from "@volcengine/pulumi";
 *
 * const fooVpc = new volcengine.vpc.Vpc("fooVpc", {
 *     vpcName: "acc-test-project1",
 *     cidrBlock: "172.16.0.0/16",
 * });
 * const fooSubnet = new volcengine.vpc.Subnet("fooSubnet", {
 *     subnetName: "acc-subnet-test-2",
 *     cidrBlock: "172.16.0.0/24",
 *     zoneId: "cn-beijing-a",
 *     vpcId: fooVpc.id,
 * });
 * const fooSecurityGroup = new volcengine.vpc.SecurityGroup("fooSecurityGroup", {
 *     vpcId: fooVpc.id,
 *     securityGroupName: "acc-test-security-group2",
 * });
 * const fooInstance = new volcengine.ecs.Instance("fooInstance", {
 *     imageId: "image-ybqi99s7yq8rx7mnk44b",
 *     instanceType: "ecs.g1ie.large",
 *     instanceName: "acc-test-ecs-name2",
 *     password: "93f0cb0614Aab12",
 *     instanceChargeType: "PostPaid",
 *     systemVolumeType: "ESSD_PL0",
 *     systemVolumeSize: 40,
 *     subnetId: fooSubnet.id,
 *     securityGroupIds: [fooSecurityGroup.id],
 * });
 * const foo2 = new volcengine.ecs.Instance("foo2", {
 *     imageId: "image-ybqi99s7yq8rx7mnk44b",
 *     instanceType: "ecs.g1ie.large",
 *     instanceName: "acc-test-ecs-name2",
 *     password: "93f0cb0614Aab12",
 *     instanceChargeType: "PostPaid",
 *     systemVolumeType: "ESSD_PL0",
 *     systemVolumeSize: 40,
 *     subnetId: fooSubnet.id,
 *     securityGroupIds: [fooSecurityGroup.id],
 * });
 * const fooCluster = new volcengine.vke.Cluster("fooCluster", {
 *     description: "created by terraform",
 *     deleteProtectionEnabled: false,
 *     clusterConfig: {
 *         subnetIds: [fooSubnet.id],
 *         apiServerPublicAccessEnabled: true,
 *         apiServerPublicAccessConfig: {
 *             publicAccessNetworkConfig: {
 *                 billingType: "PostPaidByBandwidth",
 *                 bandwidth: 1,
 *             },
 *         },
 *         resourcePublicAccessDefaultEnabled: true,
 *     },
 *     podsConfig: {
 *         podNetworkMode: "VpcCniShared",
 *         vpcCniConfig: {
 *             subnetIds: [fooSubnet.id],
 *         },
 *     },
 *     servicesConfig: {
 *         serviceCidrsv4s: ["172.30.0.0/18"],
 *     },
 *     tags: [{
 *         key: "tf-k1",
 *         value: "tf-v1",
 *     }],
 * });
 * const fooDefaultNodePool = new volcengine.vke.DefaultNodePool("fooDefaultNodePool", {
 *     clusterId: fooCluster.id,
 *     nodeConfig: {
 *         security: {
 *             login: {
 *                 password: "amw4WTdVcTRJVVFsUXpVTw==",
 *             },
 *             securityGroupIds: [fooSecurityGroup.id],
 *             securityStrategies: ["Hids"],
 *         },
 *         initializeScript: "ISMvYmluL2Jhc2gKZWNobyAx",
 *     },
 *     kubernetesConfig: {
 *         labels: [
 *             {
 *                 key: "tf-key1",
 *                 value: "tf-value1",
 *             },
 *             {
 *                 key: "tf-key2",
 *                 value: "tf-value2",
 *             },
 *         ],
 *         taints: [
 *             {
 *                 key: "tf-key3",
 *                 value: "tf-value3",
 *                 effect: "NoSchedule",
 *             },
 *             {
 *                 key: "tf-key4",
 *                 value: "tf-value4",
 *                 effect: "NoSchedule",
 *             },
 *         ],
 *         cordon: true,
 *     },
 *     tags: [{
 *         key: "tf-k1",
 *         value: "tf-v1",
 *     }],
 * });
 * const fooDefaultNodePoolBatchAttach = new volcengine.vke.DefaultNodePoolBatchAttach("fooDefaultNodePoolBatchAttach", {
 *     clusterId: fooCluster.id,
 *     defaultNodePoolId: fooDefaultNodePool.id,
 *     instances: [
 *         {
 *             instanceId: fooInstance.id,
 *             keepInstanceName: true,
 *             additionalContainerStorageEnabled: false,
 *         },
 *         {
 *             instanceId: foo2.id,
 *             keepInstanceName: true,
 *             additionalContainerStorageEnabled: false,
 *         },
 *     ],
 *     kubernetesConfig: {
 *         labels: [
 *             {
 *                 key: "tf-key1",
 *                 value: "tf-value1",
 *             },
 *             {
 *                 key: "tf-key2",
 *                 value: "tf-value2",
 *             },
 *         ],
 *         taints: [
 *             {
 *                 key: "tf-key3",
 *                 value: "tf-value3",
 *                 effect: "NoSchedule",
 *             },
 *             {
 *                 key: "tf-key4",
 *                 value: "tf-value4",
 *                 effect: "NoSchedule",
 *             },
 *         ],
 *         cordon: true,
 *     },
 * });
 * ```
 */
class DefaultNodePoolBatchAttach extends pulumi.CustomResource {
    /**
     * Get an existing DefaultNodePoolBatchAttach 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 DefaultNodePoolBatchAttach(name, state, Object.assign(Object.assign({}, opts), { id: id }));
    }
    /**
     * Returns true if the given object is an instance of DefaultNodePoolBatchAttach.  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'] === DefaultNodePoolBatchAttach.__pulumiType;
    }
    constructor(name, argsOrState, opts) {
        let resourceInputs = {};
        opts = opts || {};
        if (opts.id) {
            const state = argsOrState;
            resourceInputs["clusterId"] = state ? state.clusterId : undefined;
            resourceInputs["defaultNodePoolId"] = state ? state.defaultNodePoolId : undefined;
            resourceInputs["instances"] = state ? state.instances : undefined;
            resourceInputs["isImport"] = state ? state.isImport : undefined;
            resourceInputs["kubernetesConfig"] = state ? state.kubernetesConfig : undefined;
            resourceInputs["nodeConfigs"] = state ? state.nodeConfigs : undefined;
            resourceInputs["tags"] = state ? state.tags : undefined;
        }
        else {
            const args = argsOrState;
            if ((!args || args.clusterId === undefined) && !opts.urn) {
                throw new Error("Missing required property 'clusterId'");
            }
            if ((!args || args.defaultNodePoolId === undefined) && !opts.urn) {
                throw new Error("Missing required property 'defaultNodePoolId'");
            }
            resourceInputs["clusterId"] = args ? args.clusterId : undefined;
            resourceInputs["defaultNodePoolId"] = args ? args.defaultNodePoolId : undefined;
            resourceInputs["instances"] = args ? args.instances : undefined;
            resourceInputs["kubernetesConfig"] = args ? args.kubernetesConfig : undefined;
            resourceInputs["isImport"] = undefined /*out*/;
            resourceInputs["nodeConfigs"] = undefined /*out*/;
            resourceInputs["tags"] = undefined /*out*/;
        }
        opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
        super(DefaultNodePoolBatchAttach.__pulumiType, name, resourceInputs, opts);
    }
}
exports.DefaultNodePoolBatchAttach = DefaultNodePoolBatchAttach;
/** @internal */
DefaultNodePoolBatchAttach.__pulumiType = 'volcengine:vke/defaultNodePoolBatchAttach:DefaultNodePoolBatchAttach';
//# sourceMappingURL=defaultNodePoolBatchAttach.js.map