1. Packages
  2. OVH
  3. API Docs
  4. CloudProject
  5. getKubeNodePool
OVHCloud v1.0.0 published on Wednesday, Oct 30, 2024 by OVHcloud

ovh.CloudProject.getKubeNodePool

Explore with Pulumi AI

ovh logo
OVHCloud v1.0.0 published on Wednesday, Oct 30, 2024 by OVHcloud

    Use this data source to get a OVHcloud Managed Kubernetes node pool.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as ovh from "@pulumi/ovh";
    
    const nodepool = ovh.CloudProject.getKubeNodePool({
        serviceName: "XXXXXX",
        kubeId: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxx",
        name: "xxxxxx",
    });
    export const maxNodes = nodepool.then(nodepool => nodepool.maxNodes);
    
    import pulumi
    import pulumi_ovh as ovh
    
    nodepool = ovh.CloudProject.get_kube_node_pool(service_name="XXXXXX",
        kube_id="xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxx",
        name="xxxxxx")
    pulumi.export("maxNodes", nodepool.max_nodes)
    
    package main
    
    import (
    	"github.com/ovh/pulumi-ovh/sdk/go/ovh/CloudProject"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		nodepool, err := CloudProject.GetKubeNodePool(ctx, &cloudproject.GetKubeNodePoolArgs{
    			ServiceName: "XXXXXX",
    			KubeId:      "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxx",
    			Name:        "xxxxxx",
    		}, nil)
    		if err != nil {
    			return err
    		}
    		ctx.Export("maxNodes", nodepool.MaxNodes)
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Ovh = Pulumi.Ovh;
    
    return await Deployment.RunAsync(() => 
    {
        var nodepool = Ovh.CloudProject.GetKubeNodePool.Invoke(new()
        {
            ServiceName = "XXXXXX",
            KubeId = "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxx",
            Name = "xxxxxx",
        });
    
        return new Dictionary<string, object?>
        {
            ["maxNodes"] = nodepool.Apply(getKubeNodePoolResult => getKubeNodePoolResult.MaxNodes),
        };
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.ovh.CloudProject.CloudProjectFunctions;
    import com.pulumi.ovh.CloudProject.inputs.GetKubeNodePoolArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            final var nodepool = CloudProjectFunctions.getKubeNodePool(GetKubeNodePoolArgs.builder()
                .serviceName("XXXXXX")
                .kubeId("xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxx")
                .name("xxxxxx")
                .build());
    
            ctx.export("maxNodes", nodepool.applyValue(getKubeNodePoolResult -> getKubeNodePoolResult.maxNodes()));
        }
    }
    
    variables:
      nodepool:
        fn::invoke:
          Function: ovh:CloudProject:getKubeNodePool
          Arguments:
            serviceName: XXXXXX
            kubeId: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxx
            name: xxxxxx
    outputs:
      maxNodes: ${nodepool.maxNodes}
    

    Using getKubeNodePool

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getKubeNodePool(args: GetKubeNodePoolArgs, opts?: InvokeOptions): Promise<GetKubeNodePoolResult>
    function getKubeNodePoolOutput(args: GetKubeNodePoolOutputArgs, opts?: InvokeOptions): Output<GetKubeNodePoolResult>
    def get_kube_node_pool(kube_id: Optional[str] = None,
                           name: Optional[str] = None,
                           service_name: Optional[str] = None,
                           template: Optional[_cloudproject.GetKubeNodePoolTemplate] = None,
                           opts: Optional[InvokeOptions] = None) -> GetKubeNodePoolResult
    def get_kube_node_pool_output(kube_id: Optional[pulumi.Input[str]] = None,
                           name: Optional[pulumi.Input[str]] = None,
                           service_name: Optional[pulumi.Input[str]] = None,
                           template: Optional[pulumi.Input[_cloudproject.GetKubeNodePoolTemplateArgs]] = None,
                           opts: Optional[InvokeOptions] = None) -> Output[GetKubeNodePoolResult]
    func GetKubeNodePool(ctx *Context, args *GetKubeNodePoolArgs, opts ...InvokeOption) (*GetKubeNodePoolResult, error)
    func GetKubeNodePoolOutput(ctx *Context, args *GetKubeNodePoolOutputArgs, opts ...InvokeOption) GetKubeNodePoolResultOutput

    > Note: This function is named GetKubeNodePool in the Go SDK.

    public static class GetKubeNodePool 
    {
        public static Task<GetKubeNodePoolResult> InvokeAsync(GetKubeNodePoolArgs args, InvokeOptions? opts = null)
        public static Output<GetKubeNodePoolResult> Invoke(GetKubeNodePoolInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetKubeNodePoolResult> getKubeNodePool(GetKubeNodePoolArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: ovh:CloudProject/getKubeNodePool:getKubeNodePool
      arguments:
        # arguments dictionary

    The following arguments are supported:

    KubeId string
    The id of the managed kubernetes cluster.
    Name string
    The name of the node pool.
    ServiceName string
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    Template GetKubeNodePoolTemplate
    KubeId string
    The id of the managed kubernetes cluster.
    Name string
    The name of the node pool.
    ServiceName string
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    Template GetKubeNodePoolTemplate
    kubeId String
    The id of the managed kubernetes cluster.
    name String
    The name of the node pool.
    serviceName String
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    template GetKubeNodePoolTemplate
    kubeId string
    The id of the managed kubernetes cluster.
    name string
    The name of the node pool.
    serviceName string
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    template GetKubeNodePoolTemplate
    kube_id str
    The id of the managed kubernetes cluster.
    name str
    The name of the node pool.
    service_name str
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    template cloudproject.GetKubeNodePoolTemplate
    kubeId String
    The id of the managed kubernetes cluster.
    name String
    The name of the node pool.
    serviceName String
    The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    template Property Map

    getKubeNodePool Result

    The following output properties are available:

    AntiAffinity bool
    (Optional) should the pool use the anti-affinity feature. Default to false.
    Autoscale bool
    (Optional) Enable auto-scaling for the pool. Default to false.
    AutoscalingScaleDownUnneededTimeSeconds int
    (Optional) scaleDownUnneededTimeSeconds autoscaling parameter How long a node should be unneeded before it is eligible for scale down
    AutoscalingScaleDownUnreadyTimeSeconds int
    (Optional) scaleDownUnreadyTimeSeconds autoscaling parameter How long an unready node should be unneeded before it is eligible for scale down
    AutoscalingScaleDownUtilizationThreshold double
    (Optional) 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
    AvailableNodes int
    Number of nodes which are actually ready in the pool
    CreatedAt string
    Creation date
    CurrentNodes int
    Number of nodes present in the pool
    DesiredNodes int
    Number of nodes you desire in the pool
    Flavor string
    Flavor name
    FlavorName string
    a valid OVHcloud public cloud flavor ID in which the nodes will be started. Ex: "b2-7". Changing this value recreates the resource. You can find the list of flavor IDs: https://www.ovhcloud.com/fr/public-cloud/prices/
    Id string
    The provider-assigned unique ID for this managed resource.
    KubeId string
    See Argument Reference above.
    MaxNodes int
    maximum number of nodes allowed in the pool. Setting desired_nodes over this value will raise an error.
    MinNodes int
    minimum number of nodes allowed in the pool. Setting desired_nodes under this value will raise an error.
    MonthlyBilled bool
    (Optional) should the nodes be billed on a monthly basis. Default to false.
    Name string
    (Optional) The name of the nodepool. Changing this value recreates the resource. Warning: "_" char is not allowed!
    ProjectId string
    Project id
    ServiceName string
    See Argument Reference above.
    SizeStatus string
    Status describing the state between number of nodes wanted and available ones
    Status string
    Current status
    UpToDateNodes int
    Number of nodes with the latest version installed in the pool
    UpdatedAt string
    Last update date
    Template GetKubeNodePoolTemplate
    AntiAffinity bool
    (Optional) should the pool use the anti-affinity feature. Default to false.
    Autoscale bool
    (Optional) Enable auto-scaling for the pool. Default to false.
    AutoscalingScaleDownUnneededTimeSeconds int
    (Optional) scaleDownUnneededTimeSeconds autoscaling parameter How long a node should be unneeded before it is eligible for scale down
    AutoscalingScaleDownUnreadyTimeSeconds int
    (Optional) scaleDownUnreadyTimeSeconds autoscaling parameter How long an unready node should be unneeded before it is eligible for scale down
    AutoscalingScaleDownUtilizationThreshold float64
    (Optional) 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
    AvailableNodes int
    Number of nodes which are actually ready in the pool
    CreatedAt string
    Creation date
    CurrentNodes int
    Number of nodes present in the pool
    DesiredNodes int
    Number of nodes you desire in the pool
    Flavor string
    Flavor name
    FlavorName string
    a valid OVHcloud public cloud flavor ID in which the nodes will be started. Ex: "b2-7". Changing this value recreates the resource. You can find the list of flavor IDs: https://www.ovhcloud.com/fr/public-cloud/prices/
    Id string
    The provider-assigned unique ID for this managed resource.
    KubeId string
    See Argument Reference above.
    MaxNodes int
    maximum number of nodes allowed in the pool. Setting desired_nodes over this value will raise an error.
    MinNodes int
    minimum number of nodes allowed in the pool. Setting desired_nodes under this value will raise an error.
    MonthlyBilled bool
    (Optional) should the nodes be billed on a monthly basis. Default to false.
    Name string
    (Optional) The name of the nodepool. Changing this value recreates the resource. Warning: "_" char is not allowed!
    ProjectId string
    Project id
    ServiceName string
    See Argument Reference above.
    SizeStatus string
    Status describing the state between number of nodes wanted and available ones
    Status string
    Current status
    UpToDateNodes int
    Number of nodes with the latest version installed in the pool
    UpdatedAt string
    Last update date
    Template GetKubeNodePoolTemplate
    antiAffinity Boolean
    (Optional) should the pool use the anti-affinity feature. Default to false.
    autoscale Boolean
    (Optional) Enable auto-scaling for the pool. Default to false.
    autoscalingScaleDownUnneededTimeSeconds Integer
    (Optional) scaleDownUnneededTimeSeconds autoscaling parameter How long a node should be unneeded before it is eligible for scale down
    autoscalingScaleDownUnreadyTimeSeconds Integer
    (Optional) scaleDownUnreadyTimeSeconds autoscaling parameter How long an unready node should be unneeded before it is eligible for scale down
    autoscalingScaleDownUtilizationThreshold Double
    (Optional) 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
    availableNodes Integer
    Number of nodes which are actually ready in the pool
    createdAt String
    Creation date
    currentNodes Integer
    Number of nodes present in the pool
    desiredNodes Integer
    Number of nodes you desire in the pool
    flavor String
    Flavor name
    flavorName String
    a valid OVHcloud public cloud flavor ID in which the nodes will be started. Ex: "b2-7". Changing this value recreates the resource. You can find the list of flavor IDs: https://www.ovhcloud.com/fr/public-cloud/prices/
    id String
    The provider-assigned unique ID for this managed resource.
    kubeId String
    See Argument Reference above.
    maxNodes Integer
    maximum number of nodes allowed in the pool. Setting desired_nodes over this value will raise an error.
    minNodes Integer
    minimum number of nodes allowed in the pool. Setting desired_nodes under this value will raise an error.
    monthlyBilled Boolean
    (Optional) should the nodes be billed on a monthly basis. Default to false.
    name String
    (Optional) The name of the nodepool. Changing this value recreates the resource. Warning: "_" char is not allowed!
    projectId String
    Project id
    serviceName String
    See Argument Reference above.
    sizeStatus String
    Status describing the state between number of nodes wanted and available ones
    status String
    Current status
    upToDateNodes Integer
    Number of nodes with the latest version installed in the pool
    updatedAt String
    Last update date
    template GetKubeNodePoolTemplate
    antiAffinity boolean
    (Optional) should the pool use the anti-affinity feature. Default to false.
    autoscale boolean
    (Optional) Enable auto-scaling for the pool. Default to false.
    autoscalingScaleDownUnneededTimeSeconds number
    (Optional) scaleDownUnneededTimeSeconds autoscaling parameter How long a node should be unneeded before it is eligible for scale down
    autoscalingScaleDownUnreadyTimeSeconds number
    (Optional) scaleDownUnreadyTimeSeconds autoscaling parameter How long an unready node should be unneeded before it is eligible for scale down
    autoscalingScaleDownUtilizationThreshold number
    (Optional) 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
    availableNodes number
    Number of nodes which are actually ready in the pool
    createdAt string
    Creation date
    currentNodes number
    Number of nodes present in the pool
    desiredNodes number
    Number of nodes you desire in the pool
    flavor string
    Flavor name
    flavorName string
    a valid OVHcloud public cloud flavor ID in which the nodes will be started. Ex: "b2-7". Changing this value recreates the resource. You can find the list of flavor IDs: https://www.ovhcloud.com/fr/public-cloud/prices/
    id string
    The provider-assigned unique ID for this managed resource.
    kubeId string
    See Argument Reference above.
    maxNodes number
    maximum number of nodes allowed in the pool. Setting desired_nodes over this value will raise an error.
    minNodes number
    minimum number of nodes allowed in the pool. Setting desired_nodes under this value will raise an error.
    monthlyBilled boolean
    (Optional) should the nodes be billed on a monthly basis. Default to false.
    name string
    (Optional) The name of the nodepool. Changing this value recreates the resource. Warning: "_" char is not allowed!
    projectId string
    Project id
    serviceName string
    See Argument Reference above.
    sizeStatus string
    Status describing the state between number of nodes wanted and available ones
    status string
    Current status
    upToDateNodes number
    Number of nodes with the latest version installed in the pool
    updatedAt string
    Last update date
    template GetKubeNodePoolTemplate
    anti_affinity bool
    (Optional) should the pool use the anti-affinity feature. Default to false.
    autoscale bool
    (Optional) Enable auto-scaling for the pool. Default to false.
    autoscaling_scale_down_unneeded_time_seconds int
    (Optional) scaleDownUnneededTimeSeconds autoscaling parameter How long a node should be unneeded before it is eligible for scale down
    autoscaling_scale_down_unready_time_seconds int
    (Optional) scaleDownUnreadyTimeSeconds autoscaling parameter How long an unready node should be unneeded before it is eligible for scale down
    autoscaling_scale_down_utilization_threshold float
    (Optional) 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
    available_nodes int
    Number of nodes which are actually ready in the pool
    created_at str
    Creation date
    current_nodes int
    Number of nodes present in the pool
    desired_nodes int
    Number of nodes you desire in the pool
    flavor str
    Flavor name
    flavor_name str
    a valid OVHcloud public cloud flavor ID in which the nodes will be started. Ex: "b2-7". Changing this value recreates the resource. You can find the list of flavor IDs: https://www.ovhcloud.com/fr/public-cloud/prices/
    id str
    The provider-assigned unique ID for this managed resource.
    kube_id str
    See Argument Reference above.
    max_nodes int
    maximum number of nodes allowed in the pool. Setting desired_nodes over this value will raise an error.
    min_nodes int
    minimum number of nodes allowed in the pool. Setting desired_nodes under this value will raise an error.
    monthly_billed bool
    (Optional) should the nodes be billed on a monthly basis. Default to false.
    name str
    (Optional) The name of the nodepool. Changing this value recreates the resource. Warning: "_" char is not allowed!
    project_id str
    Project id
    service_name str
    See Argument Reference above.
    size_status str
    Status describing the state between number of nodes wanted and available ones
    status str
    Current status
    up_to_date_nodes int
    Number of nodes with the latest version installed in the pool
    updated_at str
    Last update date
    template cloudproject.GetKubeNodePoolTemplate
    antiAffinity Boolean
    (Optional) should the pool use the anti-affinity feature. Default to false.
    autoscale Boolean
    (Optional) Enable auto-scaling for the pool. Default to false.
    autoscalingScaleDownUnneededTimeSeconds Number
    (Optional) scaleDownUnneededTimeSeconds autoscaling parameter How long a node should be unneeded before it is eligible for scale down
    autoscalingScaleDownUnreadyTimeSeconds Number
    (Optional) scaleDownUnreadyTimeSeconds autoscaling parameter How long an unready node should be unneeded before it is eligible for scale down
    autoscalingScaleDownUtilizationThreshold Number
    (Optional) 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
    availableNodes Number
    Number of nodes which are actually ready in the pool
    createdAt String
    Creation date
    currentNodes Number
    Number of nodes present in the pool
    desiredNodes Number
    Number of nodes you desire in the pool
    flavor String
    Flavor name
    flavorName String
    a valid OVHcloud public cloud flavor ID in which the nodes will be started. Ex: "b2-7". Changing this value recreates the resource. You can find the list of flavor IDs: https://www.ovhcloud.com/fr/public-cloud/prices/
    id String
    The provider-assigned unique ID for this managed resource.
    kubeId String
    See Argument Reference above.
    maxNodes Number
    maximum number of nodes allowed in the pool. Setting desired_nodes over this value will raise an error.
    minNodes Number
    minimum number of nodes allowed in the pool. Setting desired_nodes under this value will raise an error.
    monthlyBilled Boolean
    (Optional) should the nodes be billed on a monthly basis. Default to false.
    name String
    (Optional) The name of the nodepool. Changing this value recreates the resource. Warning: "_" char is not allowed!
    projectId String
    Project id
    serviceName String
    See Argument Reference above.
    sizeStatus String
    Status describing the state between number of nodes wanted and available ones
    status String
    Current status
    upToDateNodes Number
    Number of nodes with the latest version installed in the pool
    updatedAt String
    Last update date
    template Property Map

    Supporting Types

    GetKubeNodePoolTemplate

    GetKubeNodePoolTemplateMetadata

    Annotations Dictionary<string, string>
    annotations
    Finalizers List<string>
    finalizers
    Labels Dictionary<string, string>
    labels
    Annotations map[string]string
    annotations
    Finalizers []string
    finalizers
    Labels map[string]string
    labels
    annotations Map<String,String>
    annotations
    finalizers List<String>
    finalizers
    labels Map<String,String>
    labels
    annotations {[key: string]: string}
    annotations
    finalizers string[]
    finalizers
    labels {[key: string]: string}
    labels
    annotations Mapping[str, str]
    annotations
    finalizers Sequence[str]
    finalizers
    labels Mapping[str, str]
    labels
    annotations Map<String>
    annotations
    finalizers List<String>
    finalizers
    labels Map<String>
    labels

    GetKubeNodePoolTemplateSpec

    Taints List<ImmutableDictionary<string, string>>
    taints
    Unschedulable bool
    unschedulable
    Taints []map[string]string
    taints
    Unschedulable bool
    unschedulable
    taints List<Map<String,String>>
    taints
    unschedulable Boolean
    unschedulable
    taints {[key: string]: string}[]
    taints
    unschedulable boolean
    unschedulable
    taints Sequence[Mapping[str, str]]
    taints
    unschedulable bool
    unschedulable
    taints List<Map<String>>
    taints
    unschedulable Boolean
    unschedulable

    Package Details

    Repository
    ovh ovh/pulumi-ovh
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the ovh Terraform Provider.
    ovh logo
    OVHCloud v1.0.0 published on Wednesday, Oct 30, 2024 by OVHcloud