"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! ***
Object.defineProperty(exports, "__esModule", { value: true });
exports.AwsNodePool = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("../utilities");
/**
 * An Anthos node pool running on AWS.
 *
 * For more information, see:
 * * [Multicloud overview](https://cloud.google.com/kubernetes-engine/multi-cloud/docs)
 * ## Example Usage
 *
 * ### Basic_aws_cluster
 * A basic example of a containeraws node pool
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as gcp from "@pulumi/gcp";
 *
 * const versions = gcp.container.getAwsVersions({
 *     project: "my-project-name",
 *     location: "us-west1",
 * });
 * const primary = new gcp.container.AwsCluster("primary", {
 *     authorization: {
 *         adminUsers: [{
 *             username: "my@service-account.com",
 *         }],
 *     },
 *     awsRegion: "my-aws-region",
 *     controlPlane: {
 *         awsServicesAuthentication: {
 *             roleArn: "arn:aws:iam::012345678910:role/my--1p-dev-oneplatform",
 *             roleSessionName: "my--1p-dev-session",
 *         },
 *         configEncryption: {
 *             kmsKeyArn: "arn:aws:kms:my-aws-region:012345678910:key/12345678-1234-1234-1234-123456789111",
 *         },
 *         databaseEncryption: {
 *             kmsKeyArn: "arn:aws:kms:my-aws-region:012345678910:key/12345678-1234-1234-1234-123456789111",
 *         },
 *         iamInstanceProfile: "my--1p-dev-controlplane",
 *         subnetIds: ["subnet-00000000000000000"],
 *         version: versions.then(versions => versions.validVersions?.[0]),
 *         instanceType: "t3.medium",
 *         mainVolume: {
 *             iops: 3000,
 *             kmsKeyArn: "arn:aws:kms:my-aws-region:012345678910:key/12345678-1234-1234-1234-123456789111",
 *             sizeGib: 10,
 *             volumeType: "GP3",
 *         },
 *         proxyConfig: {
 *             secretArn: "arn:aws:secretsmanager:us-west-2:126285863215:secret:proxy_config20210824150329476300000001-ABCDEF",
 *             secretVersion: "12345678-ABCD-EFGH-IJKL-987654321098",
 *         },
 *         rootVolume: {
 *             iops: 3000,
 *             kmsKeyArn: "arn:aws:kms:my-aws-region:012345678910:key/12345678-1234-1234-1234-123456789111",
 *             sizeGib: 10,
 *             volumeType: "GP3",
 *         },
 *         securityGroupIds: ["sg-00000000000000000"],
 *         sshConfig: {
 *             ec2KeyPair: "my--1p-dev-ssh",
 *         },
 *         tags: {
 *             owner: "my@service-account.com",
 *         },
 *     },
 *     fleet: {
 *         project: "my-project-number",
 *     },
 *     location: "us-west1",
 *     name: "name",
 *     networking: {
 *         podAddressCidrBlocks: ["10.2.0.0/16"],
 *         serviceAddressCidrBlocks: ["10.1.0.0/16"],
 *         vpcId: "vpc-00000000000000000",
 *     },
 *     annotations: {
 *         "label-one": "value-one",
 *     },
 *     description: "A sample aws cluster",
 *     project: "my-project-name",
 * });
 * const primaryAwsNodePool = new gcp.container.AwsNodePool("primary", {
 *     autoscaling: {
 *         maxNodeCount: 5,
 *         minNodeCount: 1,
 *     },
 *     cluster: primary.name,
 *     config: {
 *         configEncryption: {
 *             kmsKeyArn: "arn:aws:kms:my-aws-region:012345678910:key/12345678-1234-1234-1234-123456789111",
 *         },
 *         iamInstanceProfile: "my--1p-dev-nodepool",
 *         instanceType: "t3.medium",
 *         labels: {
 *             "label-one": "value-one",
 *         },
 *         rootVolume: {
 *             iops: 3000,
 *             kmsKeyArn: "arn:aws:kms:my-aws-region:012345678910:key/12345678-1234-1234-1234-123456789111",
 *             sizeGib: 10,
 *             volumeType: "GP3",
 *         },
 *         securityGroupIds: ["sg-00000000000000000"],
 *         proxyConfig: {
 *             secretArn: "arn:aws:secretsmanager:us-west-2:126285863215:secret:proxy_config20210824150329476300000001-ABCDEF",
 *             secretVersion: "12345678-ABCD-EFGH-IJKL-987654321098",
 *         },
 *         sshConfig: {
 *             ec2KeyPair: "my--1p-dev-ssh",
 *         },
 *         tags: {
 *             "tag-one": "value-one",
 *         },
 *         taints: [{
 *             effect: "PREFER_NO_SCHEDULE",
 *             key: "taint-key",
 *             value: "taint-value",
 *         }],
 *     },
 *     location: "us-west1",
 *     maxPodsConstraint: {
 *         maxPodsPerNode: 110,
 *     },
 *     name: "node-pool-name",
 *     subnetId: "subnet-00000000000000000",
 *     version: versions.then(versions => versions.validVersions?.[0]),
 *     annotations: {
 *         "label-one": "value-one",
 *     },
 *     management: {
 *         autoRepair: true,
 *     },
 *     kubeletConfig: {
 *         cpuManagerPolicy: "none",
 *         cpuCfsQuota: true,
 *         cpuCfsQuotaPeriod: "100ms",
 *         podPidsLimit: 1024,
 *     },
 *     project: "my-project-name",
 * });
 * ```
 * ### Basic_enum_aws_cluster
 * A basic example of a containeraws node pool with lowercase enums
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as gcp from "@pulumi/gcp";
 *
 * const versions = gcp.container.getAwsVersions({
 *     project: "my-project-name",
 *     location: "us-west1",
 * });
 * const primary = new gcp.container.AwsCluster("primary", {
 *     authorization: {
 *         adminUsers: [{
 *             username: "my@service-account.com",
 *         }],
 *     },
 *     awsRegion: "my-aws-region",
 *     controlPlane: {
 *         awsServicesAuthentication: {
 *             roleArn: "arn:aws:iam::012345678910:role/my--1p-dev-oneplatform",
 *             roleSessionName: "my--1p-dev-session",
 *         },
 *         configEncryption: {
 *             kmsKeyArn: "arn:aws:kms:my-aws-region:012345678910:key/12345678-1234-1234-1234-123456789111",
 *         },
 *         databaseEncryption: {
 *             kmsKeyArn: "arn:aws:kms:my-aws-region:012345678910:key/12345678-1234-1234-1234-123456789111",
 *         },
 *         iamInstanceProfile: "my--1p-dev-controlplane",
 *         subnetIds: ["subnet-00000000000000000"],
 *         version: versions.then(versions => versions.validVersions?.[0]),
 *         instanceType: "t3.medium",
 *         mainVolume: {
 *             iops: 3000,
 *             kmsKeyArn: "arn:aws:kms:my-aws-region:012345678910:key/12345678-1234-1234-1234-123456789111",
 *             sizeGib: 10,
 *             volumeType: "GP3",
 *         },
 *         proxyConfig: {
 *             secretArn: "arn:aws:secretsmanager:us-west-2:126285863215:secret:proxy_config20210824150329476300000001-ABCDEF",
 *             secretVersion: "12345678-ABCD-EFGH-IJKL-987654321098",
 *         },
 *         rootVolume: {
 *             iops: 3000,
 *             kmsKeyArn: "arn:aws:kms:my-aws-region:012345678910:key/12345678-1234-1234-1234-123456789111",
 *             sizeGib: 10,
 *             volumeType: "GP3",
 *         },
 *         securityGroupIds: ["sg-00000000000000000"],
 *         sshConfig: {
 *             ec2KeyPair: "my--1p-dev-ssh",
 *         },
 *         tags: {
 *             owner: "my@service-account.com",
 *         },
 *     },
 *     fleet: {
 *         project: "my-project-number",
 *     },
 *     location: "us-west1",
 *     name: "name",
 *     networking: {
 *         podAddressCidrBlocks: ["10.2.0.0/16"],
 *         serviceAddressCidrBlocks: ["10.1.0.0/16"],
 *         vpcId: "vpc-00000000000000000",
 *     },
 *     annotations: {
 *         "label-one": "value-one",
 *     },
 *     description: "A sample aws cluster",
 *     project: "my-project-name",
 * });
 * const primaryAwsNodePool = new gcp.container.AwsNodePool("primary", {
 *     autoscaling: {
 *         maxNodeCount: 5,
 *         minNodeCount: 1,
 *     },
 *     cluster: primary.name,
 *     config: {
 *         configEncryption: {
 *             kmsKeyArn: "arn:aws:kms:my-aws-region:012345678910:key/12345678-1234-1234-1234-123456789111",
 *         },
 *         iamInstanceProfile: "my--1p-dev-nodepool",
 *         instanceType: "t3.medium",
 *         labels: {
 *             "label-one": "value-one",
 *         },
 *         rootVolume: {
 *             iops: 3000,
 *             kmsKeyArn: "arn:aws:kms:my-aws-region:012345678910:key/12345678-1234-1234-1234-123456789111",
 *             sizeGib: 10,
 *             volumeType: "gp3",
 *         },
 *         securityGroupIds: ["sg-00000000000000000"],
 *         proxyConfig: {
 *             secretArn: "arn:aws:secretsmanager:us-west-2:126285863215:secret:proxy_config20210824150329476300000001-ABCDEF",
 *             secretVersion: "12345678-ABCD-EFGH-IJKL-987654321098",
 *         },
 *         sshConfig: {
 *             ec2KeyPair: "my--1p-dev-ssh",
 *         },
 *         tags: {
 *             "tag-one": "value-one",
 *         },
 *         taints: [{
 *             effect: "prefer_no_schedule",
 *             key: "taint-key",
 *             value: "taint-value",
 *         }],
 *     },
 *     location: "us-west1",
 *     maxPodsConstraint: {
 *         maxPodsPerNode: 110,
 *     },
 *     name: "node-pool-name",
 *     subnetId: "subnet-00000000000000000",
 *     version: versions.then(versions => versions.validVersions?.[0]),
 *     annotations: {
 *         "label-one": "value-one",
 *     },
 *     project: "my-project-name",
 * });
 * ```
 * ### Beta_basic_enum_aws_cluster
 * A basic example of a containeraws node pool with lowercase enums (beta)
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as gcp from "@pulumi/gcp";
 *
 * const versions = gcp.container.getAwsVersions({
 *     project: "my-project-name",
 *     location: "us-west1",
 * });
 * const primary = new gcp.container.AwsCluster("primary", {
 *     authorization: {
 *         adminUsers: [{
 *             username: "my@service-account.com",
 *         }],
 *     },
 *     awsRegion: "my-aws-region",
 *     controlPlane: {
 *         awsServicesAuthentication: {
 *             roleArn: "arn:aws:iam::012345678910:role/my--1p-dev-oneplatform",
 *             roleSessionName: "my--1p-dev-session",
 *         },
 *         configEncryption: {
 *             kmsKeyArn: "arn:aws:kms:my-aws-region:012345678910:key/12345678-1234-1234-1234-123456789111",
 *         },
 *         databaseEncryption: {
 *             kmsKeyArn: "arn:aws:kms:my-aws-region:012345678910:key/12345678-1234-1234-1234-123456789111",
 *         },
 *         iamInstanceProfile: "my--1p-dev-controlplane",
 *         subnetIds: ["subnet-00000000000000000"],
 *         version: versions.then(versions => versions.validVersions?.[0]),
 *         instanceType: "t3.medium",
 *         mainVolume: {
 *             iops: 3000,
 *             kmsKeyArn: "arn:aws:kms:my-aws-region:012345678910:key/12345678-1234-1234-1234-123456789111",
 *             sizeGib: 10,
 *             volumeType: "GP3",
 *         },
 *         proxyConfig: {
 *             secretArn: "arn:aws:secretsmanager:us-west-2:126285863215:secret:proxy_config20210824150329476300000001-ABCDEF",
 *             secretVersion: "12345678-ABCD-EFGH-IJKL-987654321098",
 *         },
 *         rootVolume: {
 *             iops: 3000,
 *             kmsKeyArn: "arn:aws:kms:my-aws-region:012345678910:key/12345678-1234-1234-1234-123456789111",
 *             sizeGib: 10,
 *             volumeType: "GP3",
 *         },
 *         securityGroupIds: ["sg-00000000000000000"],
 *         sshConfig: {
 *             ec2KeyPair: "my--1p-dev-ssh",
 *         },
 *         tags: {
 *             owner: "my@service-account.com",
 *         },
 *     },
 *     fleet: {
 *         project: "my-project-number",
 *     },
 *     location: "us-west1",
 *     name: "name",
 *     networking: {
 *         podAddressCidrBlocks: ["10.2.0.0/16"],
 *         serviceAddressCidrBlocks: ["10.1.0.0/16"],
 *         vpcId: "vpc-00000000000000000",
 *     },
 *     annotations: {
 *         "label-one": "value-one",
 *     },
 *     description: "A sample aws cluster",
 *     project: "my-project-name",
 * });
 * const primaryAwsNodePool = new gcp.container.AwsNodePool("primary", {
 *     autoscaling: {
 *         maxNodeCount: 5,
 *         minNodeCount: 1,
 *     },
 *     cluster: primary.name,
 *     config: {
 *         configEncryption: {
 *             kmsKeyArn: "arn:aws:kms:my-aws-region:012345678910:key/12345678-1234-1234-1234-123456789111",
 *         },
 *         iamInstanceProfile: "my--1p-dev-nodepool",
 *         instanceType: "t3.medium",
 *         labels: {
 *             "label-one": "value-one",
 *         },
 *         rootVolume: {
 *             iops: 3000,
 *             kmsKeyArn: "arn:aws:kms:my-aws-region:012345678910:key/12345678-1234-1234-1234-123456789111",
 *             sizeGib: 10,
 *             volumeType: "gp3",
 *         },
 *         securityGroupIds: ["sg-00000000000000000"],
 *         proxyConfig: {
 *             secretArn: "arn:aws:secretsmanager:us-west-2:126285863215:secret:proxy_config20210824150329476300000001-ABCDEF",
 *             secretVersion: "12345678-ABCD-EFGH-IJKL-987654321098",
 *         },
 *         sshConfig: {
 *             ec2KeyPair: "my--1p-dev-ssh",
 *         },
 *         tags: {
 *             "tag-one": "value-one",
 *         },
 *         taints: [{
 *             effect: "prefer_no_schedule",
 *             key: "taint-key",
 *             value: "taint-value",
 *         }],
 *         instancePlacement: {
 *             tenancy: "dedicated",
 *         },
 *         imageType: "ubuntu",
 *     },
 *     location: "us-west1",
 *     maxPodsConstraint: {
 *         maxPodsPerNode: 110,
 *     },
 *     name: "node-pool-name",
 *     subnetId: "subnet-00000000000000000",
 *     version: versions.then(versions => versions.validVersions?.[0]),
 *     annotations: {
 *         "label-one": "value-one",
 *     },
 *     project: "my-project-name",
 * });
 * ```
 *
 * ## Import
 *
 * NodePool can be imported using any of these accepted formats:
 *
 * * `projects/{{project}}/locations/{{location}}/awsClusters/{{cluster}}/awsNodePools/{{name}}`
 *
 * * `{{project}}/{{location}}/{{cluster}}/{{name}}`
 *
 * * `{{location}}/{{cluster}}/{{name}}`
 *
 * When using the `pulumi import` command, NodePool can be imported using one of the formats above. For example:
 *
 * ```sh
 * $ pulumi import gcp:container/awsNodePool:AwsNodePool default projects/{{project}}/locations/{{location}}/awsClusters/{{cluster}}/awsNodePools/{{name}}
 * ```
 *
 * ```sh
 * $ pulumi import gcp:container/awsNodePool:AwsNodePool default {{project}}/{{location}}/{{cluster}}/{{name}}
 * ```
 *
 * ```sh
 * $ pulumi import gcp:container/awsNodePool:AwsNodePool default {{location}}/{{cluster}}/{{name}}
 * ```
 */
class AwsNodePool extends pulumi.CustomResource {
    /**
     * Get an existing AwsNodePool 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 AwsNodePool(name, state, { ...opts, id: id });
    }
    /**
     * Returns true if the given object is an instance of AwsNodePool.  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'] === AwsNodePool.__pulumiType;
    }
    constructor(name, argsOrState, opts) {
        let resourceInputs = {};
        opts = opts || {};
        if (opts.id) {
            const state = argsOrState;
            resourceInputs["annotations"] = state?.annotations;
            resourceInputs["autoscaling"] = state?.autoscaling;
            resourceInputs["cluster"] = state?.cluster;
            resourceInputs["config"] = state?.config;
            resourceInputs["createTime"] = state?.createTime;
            resourceInputs["effectiveAnnotations"] = state?.effectiveAnnotations;
            resourceInputs["etag"] = state?.etag;
            resourceInputs["kubeletConfig"] = state?.kubeletConfig;
            resourceInputs["location"] = state?.location;
            resourceInputs["management"] = state?.management;
            resourceInputs["maxPodsConstraint"] = state?.maxPodsConstraint;
            resourceInputs["name"] = state?.name;
            resourceInputs["project"] = state?.project;
            resourceInputs["reconciling"] = state?.reconciling;
            resourceInputs["state"] = state?.state;
            resourceInputs["subnetId"] = state?.subnetId;
            resourceInputs["uid"] = state?.uid;
            resourceInputs["updateSettings"] = state?.updateSettings;
            resourceInputs["updateTime"] = state?.updateTime;
            resourceInputs["version"] = state?.version;
        }
        else {
            const args = argsOrState;
            if (args?.autoscaling === undefined && !opts.urn) {
                throw new Error("Missing required property 'autoscaling'");
            }
            if (args?.cluster === undefined && !opts.urn) {
                throw new Error("Missing required property 'cluster'");
            }
            if (args?.config === undefined && !opts.urn) {
                throw new Error("Missing required property 'config'");
            }
            if (args?.location === undefined && !opts.urn) {
                throw new Error("Missing required property 'location'");
            }
            if (args?.maxPodsConstraint === undefined && !opts.urn) {
                throw new Error("Missing required property 'maxPodsConstraint'");
            }
            if (args?.subnetId === undefined && !opts.urn) {
                throw new Error("Missing required property 'subnetId'");
            }
            if (args?.version === undefined && !opts.urn) {
                throw new Error("Missing required property 'version'");
            }
            resourceInputs["annotations"] = args?.annotations;
            resourceInputs["autoscaling"] = args?.autoscaling;
            resourceInputs["cluster"] = args?.cluster;
            resourceInputs["config"] = args?.config;
            resourceInputs["kubeletConfig"] = args?.kubeletConfig;
            resourceInputs["location"] = args?.location;
            resourceInputs["management"] = args?.management;
            resourceInputs["maxPodsConstraint"] = args?.maxPodsConstraint;
            resourceInputs["name"] = args?.name;
            resourceInputs["project"] = args?.project;
            resourceInputs["subnetId"] = args?.subnetId;
            resourceInputs["updateSettings"] = args?.updateSettings;
            resourceInputs["version"] = args?.version;
            resourceInputs["createTime"] = undefined /*out*/;
            resourceInputs["effectiveAnnotations"] = undefined /*out*/;
            resourceInputs["etag"] = undefined /*out*/;
            resourceInputs["reconciling"] = undefined /*out*/;
            resourceInputs["state"] = undefined /*out*/;
            resourceInputs["uid"] = undefined /*out*/;
            resourceInputs["updateTime"] = undefined /*out*/;
        }
        opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
        super(AwsNodePool.__pulumiType, name, resourceInputs, opts);
    }
}
exports.AwsNodePool = AwsNodePool;
/** @internal */
AwsNodePool.__pulumiType = 'gcp:container/awsNodePool:AwsNodePool';
//# sourceMappingURL=awsNodePool.js.map