// *** WARNING: this file was generated by pulumi-language-nodejs. *** // *** Do not edit by hand unless you're certain you know what you are doing! *** import * as pulumi from "@pulumi/pulumi"; import * as utilities from "./utilities"; export class K8sNodeGroup extends pulumi.CustomResource { /** * Get an existing K8sNodeGroup 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. */ public static get(name: string, id: pulumi.Input, state?: K8sNodeGroupState, opts?: pulumi.CustomResourceOptions): K8sNodeGroup { return new K8sNodeGroup(name, state, { ...opts, id: id }); } /** @internal */ public static readonly __pulumiType = 'timeweb-cloud:index/k8sNodeGroup:K8sNodeGroup'; /** * Returns true if the given object is an instance of K8sNodeGroup. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ public static isInstance(obj: any): obj is K8sNodeGroup { if (obj === undefined || obj === null) { return false; } return obj['__pulumiType'] === K8sNodeGroup.__pulumiType; } /** * K8S cluster ID for which node group should be created */ declare public readonly clusterId: pulumi.Output; /** * Automatic increase/decrease of the number of nodes in a group depending on the load */ declare public readonly isAutoscaling: pulumi.Output; declare public readonly k8sNodeGroupId: pulumi.Output; /** * max count of nodes in group */ declare public readonly maxSize: pulumi.Output; /** * min count of nodes in group */ declare public readonly minSize: pulumi.Output; /** * K8S node group name */ declare public readonly name: pulumi.Output; /** * Count of nodes in group */ declare public readonly nodeCount: pulumi.Output; /** * Preset ID for nodes in group */ declare public readonly presetId: pulumi.Output; /** * Create a K8sNodeGroup resource with the given unique name, arguments, and options. * * @param name The _unique_ name of the resource. * @param args The arguments to use to populate this resource's properties. * @param opts A bag of options that control this resource's behavior. */ constructor(name: string, args: K8sNodeGroupArgs, opts?: pulumi.CustomResourceOptions) constructor(name: string, argsOrState?: K8sNodeGroupArgs | K8sNodeGroupState, opts?: pulumi.CustomResourceOptions) { let resourceInputs: pulumi.Inputs = {}; opts = opts || {}; if (opts.id) { const state = argsOrState as K8sNodeGroupState | undefined; resourceInputs["clusterId"] = state?.clusterId; resourceInputs["isAutoscaling"] = state?.isAutoscaling; resourceInputs["k8sNodeGroupId"] = state?.k8sNodeGroupId; resourceInputs["maxSize"] = state?.maxSize; resourceInputs["minSize"] = state?.minSize; resourceInputs["name"] = state?.name; resourceInputs["nodeCount"] = state?.nodeCount; resourceInputs["presetId"] = state?.presetId; } else { const args = argsOrState as K8sNodeGroupArgs | undefined; if (args?.clusterId === undefined && !opts.urn) { throw new Error("Missing required property 'clusterId'"); } if (args?.nodeCount === undefined && !opts.urn) { throw new Error("Missing required property 'nodeCount'"); } if (args?.presetId === undefined && !opts.urn) { throw new Error("Missing required property 'presetId'"); } resourceInputs["clusterId"] = args?.clusterId; resourceInputs["isAutoscaling"] = args?.isAutoscaling; resourceInputs["k8sNodeGroupId"] = args?.k8sNodeGroupId; resourceInputs["maxSize"] = args?.maxSize; resourceInputs["minSize"] = args?.minSize; resourceInputs["name"] = args?.name; resourceInputs["nodeCount"] = args?.nodeCount; resourceInputs["presetId"] = args?.presetId; } opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts); super(K8sNodeGroup.__pulumiType, name, resourceInputs, opts, false /*dependency*/, utilities.getPackage()); } } /** * Input properties used for looking up and filtering K8sNodeGroup resources. */ export interface K8sNodeGroupState { /** * K8S cluster ID for which node group should be created */ clusterId?: pulumi.Input; /** * Automatic increase/decrease of the number of nodes in a group depending on the load */ isAutoscaling?: pulumi.Input; k8sNodeGroupId?: pulumi.Input; /** * max count of nodes in group */ maxSize?: pulumi.Input; /** * min count of nodes in group */ minSize?: pulumi.Input; /** * K8S node group name */ name?: pulumi.Input; /** * Count of nodes in group */ nodeCount?: pulumi.Input; /** * Preset ID for nodes in group */ presetId?: pulumi.Input; } /** * The set of arguments for constructing a K8sNodeGroup resource. */ export interface K8sNodeGroupArgs { /** * K8S cluster ID for which node group should be created */ clusterId: pulumi.Input; /** * Automatic increase/decrease of the number of nodes in a group depending on the load */ isAutoscaling?: pulumi.Input; k8sNodeGroupId?: pulumi.Input; /** * max count of nodes in group */ maxSize?: pulumi.Input; /** * min count of nodes in group */ minSize?: pulumi.Input; /** * K8S node group name */ name?: pulumi.Input; /** * Count of nodes in group */ nodeCount: pulumi.Input; /** * Preset ID for nodes in group */ presetId: pulumi.Input; }