Ovh

v0.0.4 published on Saturday, Sep 17, 2022 by lbrlabs

getCloudProjectKube

Use this data source to get a OVH Managed Kubernetes Service cluster.

Example Usage

using System.Collections.Generic;
using Pulumi;
using Ovh = Pulumi.Ovh;

return await Deployment.RunAsync(() => 
{
    var myKubeCluster = Ovh.GetCloudProjectKube.Invoke(new()
    {
        ServiceName = "XXXXXX",
        KubeId = "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx",
    });

    return new Dictionary<string, object?>
    {
        ["version"] = myKubeCluster.Apply(getCloudProjectKubeResult => getCloudProjectKubeResult.Version),
    };
});
package main

import (
	"github.com/lbrlabs/pulumi-ovh/sdk/go/ovh"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		myKubeCluster, err := ovh.LookupCloudProjectKube(ctx, &GetCloudProjectKubeArgs{
			ServiceName: "XXXXXX",
			KubeId:      "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx",
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("version", myKubeCluster.Version)
		return nil
	})
}
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.ovh.OvhFunctions;
import com.pulumi.ovh.inputs.GetCloudProjectKubeArgs;
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 myKubeCluster = OvhFunctions.getCloudProjectKube(GetCloudProjectKubeArgs.builder()
            .serviceName("XXXXXX")
            .kubeId("xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx")
            .build());

        ctx.export("version", myKubeCluster.applyValue(getCloudProjectKubeResult -> getCloudProjectKubeResult.version()));
    }
}
import pulumi
import pulumi_ovh as ovh

my_kube_cluster = ovh.get_cloud_project_kube(service_name="XXXXXX",
    kube_id="xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx")
pulumi.export("version", my_kube_cluster.version)
import * as pulumi from "@pulumi/pulumi";
import * as ovh from "@pulumi/ovh";

const myKubeCluster = ovh.getCloudProjectKube({
    serviceName: "XXXXXX",
    kubeId: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx",
});
export const version = myKubeCluster.then(myKubeCluster => myKubeCluster.version);
variables:
  myKubeCluster:
    Fn::Invoke:
      Function: ovh:getCloudProjectKube
      Arguments:
        serviceName: XXXXXX
        kubeId: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx
outputs:
  version: ${myKubeCluster.version}

Using getCloudProjectKube

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 getCloudProjectKube(args: GetCloudProjectKubeArgs, opts?: InvokeOptions): Promise<GetCloudProjectKubeResult>
function getCloudProjectKubeOutput(args: GetCloudProjectKubeOutputArgs, opts?: InvokeOptions): Output<GetCloudProjectKubeResult>
def get_cloud_project_kube(kube_id: Optional[str] = None,
                           name: Optional[str] = None,
                           region: Optional[str] = None,
                           service_name: Optional[str] = None,
                           update_policy: Optional[str] = None,
                           version: Optional[str] = None,
                           opts: Optional[InvokeOptions] = None) -> GetCloudProjectKubeResult
def get_cloud_project_kube_output(kube_id: Optional[pulumi.Input[str]] = None,
                           name: Optional[pulumi.Input[str]] = None,
                           region: Optional[pulumi.Input[str]] = None,
                           service_name: Optional[pulumi.Input[str]] = None,
                           update_policy: Optional[pulumi.Input[str]] = None,
                           version: Optional[pulumi.Input[str]] = None,
                           opts: Optional[InvokeOptions] = None) -> Output[GetCloudProjectKubeResult]
func LookupCloudProjectKube(ctx *Context, args *LookupCloudProjectKubeArgs, opts ...InvokeOption) (*LookupCloudProjectKubeResult, error)
func LookupCloudProjectKubeOutput(ctx *Context, args *LookupCloudProjectKubeOutputArgs, opts ...InvokeOption) LookupCloudProjectKubeResultOutput

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

public static class GetCloudProjectKube 
{
    public static Task<GetCloudProjectKubeResult> InvokeAsync(GetCloudProjectKubeArgs args, InvokeOptions? opts = null)
    public static Output<GetCloudProjectKubeResult> Invoke(GetCloudProjectKubeInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetCloudProjectKubeResult> getCloudProjectKube(GetCloudProjectKubeArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
Fn::Invoke:
  Function: ovh:index/getCloudProjectKube:getCloudProjectKube
  Arguments:
    # Arguments dictionary

The following arguments are supported:

KubeId string

The id of the managed kubernetes cluster.

ServiceName string

The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.

Name string

The name of the managed kubernetes cluster.

Region string

The OVH public cloud region ID of the managed kubernetes cluster.

UpdatePolicy string

Cluster update policy. Choose between [ALWAYS_UPDATE,MINIMAL_DOWNTIME,NEVER_UPDATE]'.

Version string

Kubernetes version of the managed kubernetes cluster.

KubeId string

The id of the managed kubernetes cluster.

ServiceName string

The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.

Name string

The name of the managed kubernetes cluster.

Region string

The OVH public cloud region ID of the managed kubernetes cluster.

UpdatePolicy string

Cluster update policy. Choose between [ALWAYS_UPDATE,MINIMAL_DOWNTIME,NEVER_UPDATE]'.

Version string

Kubernetes version of the managed kubernetes cluster.

kubeId String

The id of the managed kubernetes cluster.

serviceName String

The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.

name String

The name of the managed kubernetes cluster.

region String

The OVH public cloud region ID of the managed kubernetes cluster.

updatePolicy String

Cluster update policy. Choose between [ALWAYS_UPDATE,MINIMAL_DOWNTIME,NEVER_UPDATE]'.

version String

Kubernetes version of the managed kubernetes cluster.

kubeId string

The id of the managed kubernetes cluster.

serviceName string

The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.

name string

The name of the managed kubernetes cluster.

region string

The OVH public cloud region ID of the managed kubernetes cluster.

updatePolicy string

Cluster update policy. Choose between [ALWAYS_UPDATE,MINIMAL_DOWNTIME,NEVER_UPDATE]'.

version string

Kubernetes version of the managed kubernetes cluster.

kube_id str

The id of the managed kubernetes cluster.

service_name str

The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.

name str

The name of the managed kubernetes cluster.

region str

The OVH public cloud region ID of the managed kubernetes cluster.

update_policy str

Cluster update policy. Choose between [ALWAYS_UPDATE,MINIMAL_DOWNTIME,NEVER_UPDATE]'.

version str

Kubernetes version of the managed kubernetes cluster.

kubeId String

The id of the managed kubernetes cluster.

serviceName String

The id of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.

name String

The name of the managed kubernetes cluster.

region String

The OVH public cloud region ID of the managed kubernetes cluster.

updatePolicy String

Cluster update policy. Choose between [ALWAYS_UPDATE,MINIMAL_DOWNTIME,NEVER_UPDATE]'.

version String

Kubernetes version of the managed kubernetes cluster.

getCloudProjectKube Result

The following output properties are available:

ControlPlaneIsUpToDate bool

True if control-plane is up to date.

Id string

The provider-assigned unique ID for this managed resource.

IsUpToDate bool

True if all nodes and control-plane are up to date.

KubeId string

See Argument Reference above.

NextUpgradeVersions List<string>

Kubernetes versions available for upgrade.

NodesUrl string

Cluster nodes URL.

PrivateNetworkId string

OpenStack private network (or vrack) ID to use.

ServiceName string

See Argument Reference above.

Status string

Cluster status. Should be normally set to 'READY'.

Url string

Management URL of your cluster.

Name string

The name of the managed kubernetes cluster.

Region string

The OVH public cloud region ID of the managed kubernetes cluster.

UpdatePolicy string

Cluster update policy. Choose between [ALWAYS_UPDATE,MINIMAL_DOWNTIME,NEVER_UPDATE]'.

Version string

Kubernetes version of the managed kubernetes cluster.

ControlPlaneIsUpToDate bool

True if control-plane is up to date.

Id string

The provider-assigned unique ID for this managed resource.

IsUpToDate bool

True if all nodes and control-plane are up to date.

KubeId string

See Argument Reference above.

NextUpgradeVersions []string

Kubernetes versions available for upgrade.

NodesUrl string

Cluster nodes URL.

PrivateNetworkId string

OpenStack private network (or vrack) ID to use.

ServiceName string

See Argument Reference above.

Status string

Cluster status. Should be normally set to 'READY'.

Url string

Management URL of your cluster.

Name string

The name of the managed kubernetes cluster.

Region string

The OVH public cloud region ID of the managed kubernetes cluster.

UpdatePolicy string

Cluster update policy. Choose between [ALWAYS_UPDATE,MINIMAL_DOWNTIME,NEVER_UPDATE]'.

Version string

Kubernetes version of the managed kubernetes cluster.

controlPlaneIsUpToDate Boolean

True if control-plane is up to date.

id String

The provider-assigned unique ID for this managed resource.

isUpToDate Boolean

True if all nodes and control-plane are up to date.

kubeId String

See Argument Reference above.

nextUpgradeVersions List<String>

Kubernetes versions available for upgrade.

nodesUrl String

Cluster nodes URL.

privateNetworkId String

OpenStack private network (or vrack) ID to use.

serviceName String

See Argument Reference above.

status String

Cluster status. Should be normally set to 'READY'.

url String

Management URL of your cluster.

name String

The name of the managed kubernetes cluster.

region String

The OVH public cloud region ID of the managed kubernetes cluster.

updatePolicy String

Cluster update policy. Choose between [ALWAYS_UPDATE,MINIMAL_DOWNTIME,NEVER_UPDATE]'.

version String

Kubernetes version of the managed kubernetes cluster.

controlPlaneIsUpToDate boolean

True if control-plane is up to date.

id string

The provider-assigned unique ID for this managed resource.

isUpToDate boolean

True if all nodes and control-plane are up to date.

kubeId string

See Argument Reference above.

nextUpgradeVersions string[]

Kubernetes versions available for upgrade.

nodesUrl string

Cluster nodes URL.

privateNetworkId string

OpenStack private network (or vrack) ID to use.

serviceName string

See Argument Reference above.

status string

Cluster status. Should be normally set to 'READY'.

url string

Management URL of your cluster.

name string

The name of the managed kubernetes cluster.

region string

The OVH public cloud region ID of the managed kubernetes cluster.

updatePolicy string

Cluster update policy. Choose between [ALWAYS_UPDATE,MINIMAL_DOWNTIME,NEVER_UPDATE]'.

version string

Kubernetes version of the managed kubernetes cluster.

control_plane_is_up_to_date bool

True if control-plane is up to date.

id str

The provider-assigned unique ID for this managed resource.

is_up_to_date bool

True if all nodes and control-plane are up to date.

kube_id str

See Argument Reference above.

next_upgrade_versions Sequence[str]

Kubernetes versions available for upgrade.

nodes_url str

Cluster nodes URL.

private_network_id str

OpenStack private network (or vrack) ID to use.

service_name str

See Argument Reference above.

status str

Cluster status. Should be normally set to 'READY'.

url str

Management URL of your cluster.

name str

The name of the managed kubernetes cluster.

region str

The OVH public cloud region ID of the managed kubernetes cluster.

update_policy str

Cluster update policy. Choose between [ALWAYS_UPDATE,MINIMAL_DOWNTIME,NEVER_UPDATE]'.

version str

Kubernetes version of the managed kubernetes cluster.

controlPlaneIsUpToDate Boolean

True if control-plane is up to date.

id String

The provider-assigned unique ID for this managed resource.

isUpToDate Boolean

True if all nodes and control-plane are up to date.

kubeId String

See Argument Reference above.

nextUpgradeVersions List<String>

Kubernetes versions available for upgrade.

nodesUrl String

Cluster nodes URL.

privateNetworkId String

OpenStack private network (or vrack) ID to use.

serviceName String

See Argument Reference above.

status String

Cluster status. Should be normally set to 'READY'.

url String

Management URL of your cluster.

name String

The name of the managed kubernetes cluster.

region String

The OVH public cloud region ID of the managed kubernetes cluster.

updatePolicy String

Cluster update policy. Choose between [ALWAYS_UPDATE,MINIMAL_DOWNTIME,NEVER_UPDATE]'.

version String

Kubernetes version of the managed kubernetes cluster.

Package Details

Repository
https://github.com/lbrlabs/pulumi-ovh
License
Apache-2.0
Notes

This Pulumi package is based on the ovh Terraform Provider.