import * as pulumi from "@pulumi/pulumi"; import * as inputs from "../types/input"; import * as outputs from "../types/output"; /** * Creates a nodepool in a OVHcloud Managed Kubernetes Service cluster. * * ## Example Usage * * Create a simple node pool in your Kubernetes cluster: * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as ovh from "@ovhcloud/pulumi-ovh"; * * const nodePool = new ovh.cloudproject.KubeNodePool("node_pool", { * serviceName: "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx", * kubeId: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", * name: "my-pool-1", * flavorName: "b3-8", * desiredNodes: 3, * }); * ``` * * Create a node pool on a specific availability zones for Kubernetes cluster (with multi-zones support): * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as ovh from "@ovhcloud/pulumi-ovh"; * * const nodePoolMultiZones = new ovh.cloudproject.KubeNodePool("node_pool_multi_zones", { * serviceName: "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx", * kubeId: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", * name: "my-pool-zone-a", * flavorName: "b3-8", * desiredNodes: 3, * availabilityZones: ["eu-west-par-a"], * }); * ``` * * Create an advanced node pool in your Kubernetes cluster: * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as ovh from "@ovhcloud/pulumi-ovh"; * * const pool = new ovh.cloudproject.KubeNodePool("pool", { * serviceName: "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx", * kubeId: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", * name: "my-pool", * flavorName: "b3-8", * desiredNodes: 3, * template: { * metadata: { * annotations: { * k1: "v1", * k2: "v2", * }, * finalizers: [], * labels: { * k3: "v3", * k4: "v4", * }, * }, * spec: { * unschedulable: false, * taints: [{ * effect: "PreferNoSchedule", * key: "k", * value: "v", * }], * }, * }, * }); * ``` * * ## Import * * OVHcloud Managed Kubernetes Service cluster node pool can be imported using the `service_name`, the `id` of the cluster, and the `id` of the nodepool separated by "/" E.g., * * bash * * ```sh * $ pulumi import ovh:CloudProject/kubeNodePool:KubeNodePool pool service_name/kube_id/poolid * ``` */ export declare class KubeNodePool extends pulumi.CustomResource { /** * Get an existing KubeNodePool 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: string, id: pulumi.Input, state?: KubeNodePoolState, opts?: pulumi.CustomResourceOptions): KubeNodePool; /** * Returns true if the given object is an instance of KubeNodePool. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj: any): obj is KubeNodePool; /** * should the pool use the anti-affinity feature. Default to `false`. **Changing this value recreates the resource.** */ readonly antiAffinity: pulumi.Output; /** * Configuration for floating IP attachment on pool nodes. */ readonly attachFloatingIps: pulumi.Output; /** * Enable auto-scaling for the pool. Default to `false`. */ readonly autoscale: pulumi.Output; /** * scaleDownUnneededTimeSeconds autoscaling parameter How long a node should be unneeded before it is eligible for scale down */ readonly autoscalingScaleDownUnneededTimeSeconds: pulumi.Output; /** * scaleDownUnreadyTimeSeconds autoscaling parameter How long an unready node should be unneeded before it is eligible for scale down */ readonly autoscalingScaleDownUnreadyTimeSeconds: pulumi.Output; /** * scaleDownUtilizationThreshold autoscaling parameter Node utilization level, defined as sum of requested resources divided by capacity, below which a node can be considered for scale down */ readonly autoscalingScaleDownUtilizationThreshold: pulumi.Output; /** * list of availability zones to associate the pool - **mandatory for multi-zone** cluster - only one zone is supported at the moment. */ readonly availabilityZones: pulumi.Output; /** * Number of nodes which are actually ready in the pool */ readonly availableNodes: pulumi.Output; /** * Creation date */ readonly createdAt: pulumi.Output; /** * Number of nodes present in the pool */ readonly currentNodes: pulumi.Output; /** * number of nodes to start. */ readonly desiredNodes: pulumi.Output; /** * Flavor name */ readonly flavor: pulumi.Output; /** * a valid OVHcloud public cloud flavor ID in which the nodes will be started. Ex: "b3-8". You can find the list of flavor IDs: https://www.ovhcloud.com/fr/public-cloud/prices/. **Changing this value recreates the resource.** */ readonly flavorName: pulumi.Output; /** * The id of the managed kubernetes cluster. **Changing this value recreates the resource.** */ readonly kubeId: pulumi.Output; /** * maximum number of nodes allowed in the pool. Setting `desiredNodes` over this value will raise an error. */ readonly maxNodes: pulumi.Output; /** * minimum number of nodes allowed in the pool. Setting `desiredNodes` under this value will raise an error. */ readonly minNodes: pulumi.Output; /** * should the nodes be billed on a monthly basis. Default to `false`. **Changing this value recreates the resource.** */ readonly monthlyBilled: pulumi.Output; /** * The name of the nodepool. Warning: `_` char is not allowed! **Changing this value recreates the resource.** */ readonly name: pulumi.Output; /** * Project id */ readonly projectId: pulumi.Output; /** * The id of the public cloud project. If omitted, the `OVH_CLOUD_PROJECT_SERVICE` environment variable is used. **Changing this value recreates the resource.** */ readonly serviceName: pulumi.Output; /** * Status describing the state between number of nodes wanted and available ones */ readonly sizeStatus: pulumi.Output; /** * Current status */ readonly status: pulumi.Output; /** * Node pool template */ readonly template: pulumi.Output; /** * Number of nodes with the latest version installed in the pool */ readonly upToDateNodes: pulumi.Output; /** * Last update date */ readonly updatedAt: pulumi.Output; /** * Create a KubeNodePool 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: KubeNodePoolArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering KubeNodePool resources. */ export interface KubeNodePoolState { /** * should the pool use the anti-affinity feature. Default to `false`. **Changing this value recreates the resource.** */ antiAffinity?: pulumi.Input; /** * Configuration for floating IP attachment on pool nodes. */ attachFloatingIps?: pulumi.Input; /** * Enable auto-scaling for the pool. Default to `false`. */ autoscale?: pulumi.Input; /** * scaleDownUnneededTimeSeconds autoscaling parameter How long a node should be unneeded before it is eligible for scale down */ autoscalingScaleDownUnneededTimeSeconds?: pulumi.Input; /** * scaleDownUnreadyTimeSeconds autoscaling parameter How long an unready node should be unneeded before it is eligible for scale down */ autoscalingScaleDownUnreadyTimeSeconds?: pulumi.Input; /** * scaleDownUtilizationThreshold autoscaling parameter Node utilization level, defined as sum of requested resources divided by capacity, below which a node can be considered for scale down */ autoscalingScaleDownUtilizationThreshold?: pulumi.Input; /** * list of availability zones to associate the pool - **mandatory for multi-zone** cluster - only one zone is supported at the moment. */ availabilityZones?: pulumi.Input[]>; /** * Number of nodes which are actually ready in the pool */ availableNodes?: pulumi.Input; /** * Creation date */ createdAt?: pulumi.Input; /** * Number of nodes present in the pool */ currentNodes?: pulumi.Input; /** * number of nodes to start. */ desiredNodes?: pulumi.Input; /** * Flavor name */ flavor?: pulumi.Input; /** * a valid OVHcloud public cloud flavor ID in which the nodes will be started. Ex: "b3-8". You can find the list of flavor IDs: https://www.ovhcloud.com/fr/public-cloud/prices/. **Changing this value recreates the resource.** */ flavorName?: pulumi.Input; /** * The id of the managed kubernetes cluster. **Changing this value recreates the resource.** */ kubeId?: pulumi.Input; /** * maximum number of nodes allowed in the pool. Setting `desiredNodes` over this value will raise an error. */ maxNodes?: pulumi.Input; /** * minimum number of nodes allowed in the pool. Setting `desiredNodes` under this value will raise an error. */ minNodes?: pulumi.Input; /** * should the nodes be billed on a monthly basis. Default to `false`. **Changing this value recreates the resource.** */ monthlyBilled?: pulumi.Input; /** * The name of the nodepool. Warning: `_` char is not allowed! **Changing this value recreates the resource.** */ name?: pulumi.Input; /** * Project id */ projectId?: pulumi.Input; /** * The id of the public cloud project. If omitted, the `OVH_CLOUD_PROJECT_SERVICE` environment variable is used. **Changing this value recreates the resource.** */ serviceName?: pulumi.Input; /** * Status describing the state between number of nodes wanted and available ones */ sizeStatus?: pulumi.Input; /** * Current status */ status?: pulumi.Input; /** * Node pool template */ template?: pulumi.Input; /** * Number of nodes with the latest version installed in the pool */ upToDateNodes?: pulumi.Input; /** * Last update date */ updatedAt?: pulumi.Input; } /** * The set of arguments for constructing a KubeNodePool resource. */ export interface KubeNodePoolArgs { /** * should the pool use the anti-affinity feature. Default to `false`. **Changing this value recreates the resource.** */ antiAffinity?: pulumi.Input; /** * Configuration for floating IP attachment on pool nodes. */ attachFloatingIps?: pulumi.Input; /** * Enable auto-scaling for the pool. Default to `false`. */ autoscale?: pulumi.Input; /** * scaleDownUnneededTimeSeconds autoscaling parameter How long a node should be unneeded before it is eligible for scale down */ autoscalingScaleDownUnneededTimeSeconds?: pulumi.Input; /** * scaleDownUnreadyTimeSeconds autoscaling parameter How long an unready node should be unneeded before it is eligible for scale down */ autoscalingScaleDownUnreadyTimeSeconds?: pulumi.Input; /** * scaleDownUtilizationThreshold autoscaling parameter Node utilization level, defined as sum of requested resources divided by capacity, below which a node can be considered for scale down */ autoscalingScaleDownUtilizationThreshold?: pulumi.Input; /** * list of availability zones to associate the pool - **mandatory for multi-zone** cluster - only one zone is supported at the moment. */ availabilityZones?: pulumi.Input[]>; /** * number of nodes to start. */ desiredNodes?: pulumi.Input; /** * a valid OVHcloud public cloud flavor ID in which the nodes will be started. Ex: "b3-8". You can find the list of flavor IDs: https://www.ovhcloud.com/fr/public-cloud/prices/. **Changing this value recreates the resource.** */ flavorName: pulumi.Input; /** * The id of the managed kubernetes cluster. **Changing this value recreates the resource.** */ kubeId: pulumi.Input; /** * maximum number of nodes allowed in the pool. Setting `desiredNodes` over this value will raise an error. */ maxNodes?: pulumi.Input; /** * minimum number of nodes allowed in the pool. Setting `desiredNodes` under this value will raise an error. */ minNodes?: pulumi.Input; /** * should the nodes be billed on a monthly basis. Default to `false`. **Changing this value recreates the resource.** */ monthlyBilled?: pulumi.Input; /** * The name of the nodepool. Warning: `_` char is not allowed! **Changing this value recreates the resource.** */ name?: pulumi.Input; /** * The id of the public cloud project. If omitted, the `OVH_CLOUD_PROJECT_SERVICE` environment variable is used. **Changing this value recreates the resource.** */ serviceName?: pulumi.Input; /** * Node pool template */ template?: pulumi.Input; }