1. Packages
  2. Alibaba Cloud
  3. API Docs
  4. cs
  5. getEdgeKubernetesClusters
Alibaba Cloud v3.51.0 published on Saturday, Mar 23, 2024 by Pulumi

alicloud.cs.getEdgeKubernetesClusters

Explore with Pulumi AI

alicloud logo
Alibaba Cloud v3.51.0 published on Saturday, Mar 23, 2024 by Pulumi

    This data source provides a list Container Service Edge Kubernetes Clusters on Alibaba Cloud.

    NOTE: Available in v1.103.0+

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as alicloud from "@pulumi/alicloud";
    
    const k8sClusters = alicloud.cs.getEdgeKubernetesClusters({
        nameRegex: "my-first-k8s",
        outputFile: "my-first-k8s-json",
    });
    export const output = k8sClusters.then(k8sClusters => k8sClusters.clusters);
    
    import pulumi
    import pulumi_alicloud as alicloud
    
    k8s_clusters = alicloud.cs.get_edge_kubernetes_clusters(name_regex="my-first-k8s",
        output_file="my-first-k8s-json")
    pulumi.export("output", k8s_clusters.clusters)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/cs"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		k8sClusters, err := cs.GetEdgeKubernetesClusters(ctx, &cs.GetEdgeKubernetesClustersArgs{
    			NameRegex:  pulumi.StringRef("my-first-k8s"),
    			OutputFile: pulumi.StringRef("my-first-k8s-json"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		ctx.Export("output", k8sClusters.Clusters)
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using AliCloud = Pulumi.AliCloud;
    
    return await Deployment.RunAsync(() => 
    {
        var k8sClusters = AliCloud.CS.GetEdgeKubernetesClusters.Invoke(new()
        {
            NameRegex = "my-first-k8s",
            OutputFile = "my-first-k8s-json",
        });
    
        return new Dictionary<string, object?>
        {
            ["output"] = k8sClusters.Apply(getEdgeKubernetesClustersResult => getEdgeKubernetesClustersResult.Clusters),
        };
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.alicloud.cs.CsFunctions;
    import com.pulumi.alicloud.cs.inputs.GetEdgeKubernetesClustersArgs;
    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 k8sClusters = CsFunctions.getEdgeKubernetesClusters(GetEdgeKubernetesClustersArgs.builder()
                .nameRegex("my-first-k8s")
                .outputFile("my-first-k8s-json")
                .build());
    
            ctx.export("output", k8sClusters.applyValue(getEdgeKubernetesClustersResult -> getEdgeKubernetesClustersResult.clusters()));
        }
    }
    
    variables:
      k8sClusters:
        fn::invoke:
          Function: alicloud:cs:getEdgeKubernetesClusters
          Arguments:
            nameRegex: my-first-k8s
            outputFile: my-first-k8s-json
    outputs:
      output: ${k8sClusters.clusters}
    

    Using getEdgeKubernetesClusters

    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 getEdgeKubernetesClusters(args: GetEdgeKubernetesClustersArgs, opts?: InvokeOptions): Promise<GetEdgeKubernetesClustersResult>
    function getEdgeKubernetesClustersOutput(args: GetEdgeKubernetesClustersOutputArgs, opts?: InvokeOptions): Output<GetEdgeKubernetesClustersResult>
    def get_edge_kubernetes_clusters(enable_details: Optional[bool] = None,
                                     ids: Optional[Sequence[str]] = None,
                                     name_regex: Optional[str] = None,
                                     output_file: Optional[str] = None,
                                     opts: Optional[InvokeOptions] = None) -> GetEdgeKubernetesClustersResult
    def get_edge_kubernetes_clusters_output(enable_details: Optional[pulumi.Input[bool]] = None,
                                     ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
                                     name_regex: Optional[pulumi.Input[str]] = None,
                                     output_file: Optional[pulumi.Input[str]] = None,
                                     opts: Optional[InvokeOptions] = None) -> Output[GetEdgeKubernetesClustersResult]
    func GetEdgeKubernetesClusters(ctx *Context, args *GetEdgeKubernetesClustersArgs, opts ...InvokeOption) (*GetEdgeKubernetesClustersResult, error)
    func GetEdgeKubernetesClustersOutput(ctx *Context, args *GetEdgeKubernetesClustersOutputArgs, opts ...InvokeOption) GetEdgeKubernetesClustersResultOutput

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

    public static class GetEdgeKubernetesClusters 
    {
        public static Task<GetEdgeKubernetesClustersResult> InvokeAsync(GetEdgeKubernetesClustersArgs args, InvokeOptions? opts = null)
        public static Output<GetEdgeKubernetesClustersResult> Invoke(GetEdgeKubernetesClustersInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetEdgeKubernetesClustersResult> getEdgeKubernetesClusters(GetEdgeKubernetesClustersArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: alicloud:cs/getEdgeKubernetesClusters:getEdgeKubernetesClusters
      arguments:
        # arguments dictionary

    The following arguments are supported:

    EnableDetails bool
    Ids List<string>
    Cluster IDs to filter.
    NameRegex string
    A regex string to filter results by cluster name.
    OutputFile string
    File name where to save data source results (after running pulumi preview).
    EnableDetails bool
    Ids []string
    Cluster IDs to filter.
    NameRegex string
    A regex string to filter results by cluster name.
    OutputFile string
    File name where to save data source results (after running pulumi preview).
    enableDetails Boolean
    ids List<String>
    Cluster IDs to filter.
    nameRegex String
    A regex string to filter results by cluster name.
    outputFile String
    File name where to save data source results (after running pulumi preview).
    enableDetails boolean
    ids string[]
    Cluster IDs to filter.
    nameRegex string
    A regex string to filter results by cluster name.
    outputFile string
    File name where to save data source results (after running pulumi preview).
    enable_details bool
    ids Sequence[str]
    Cluster IDs to filter.
    name_regex str
    A regex string to filter results by cluster name.
    output_file str
    File name where to save data source results (after running pulumi preview).
    enableDetails Boolean
    ids List<String>
    Cluster IDs to filter.
    nameRegex String
    A regex string to filter results by cluster name.
    outputFile String
    File name where to save data source results (after running pulumi preview).

    getEdgeKubernetesClusters Result

    The following output properties are available:

    Clusters List<Pulumi.AliCloud.CS.Outputs.GetEdgeKubernetesClustersCluster>
    A list of matched Kubernetes clusters. Each element contains the following attributes:
    Id string
    The provider-assigned unique ID for this managed resource.
    Ids List<string>
    A list of matched Kubernetes clusters' ids.
    Names List<string>
    A list of matched Kubernetes clusters' names.
    EnableDetails bool
    NameRegex string
    OutputFile string
    Clusters []GetEdgeKubernetesClustersCluster
    A list of matched Kubernetes clusters. Each element contains the following attributes:
    Id string
    The provider-assigned unique ID for this managed resource.
    Ids []string
    A list of matched Kubernetes clusters' ids.
    Names []string
    A list of matched Kubernetes clusters' names.
    EnableDetails bool
    NameRegex string
    OutputFile string
    clusters List<GetEdgeKubernetesClustersCluster>
    A list of matched Kubernetes clusters. Each element contains the following attributes:
    id String
    The provider-assigned unique ID for this managed resource.
    ids List<String>
    A list of matched Kubernetes clusters' ids.
    names List<String>
    A list of matched Kubernetes clusters' names.
    enableDetails Boolean
    nameRegex String
    outputFile String
    clusters GetEdgeKubernetesClustersCluster[]
    A list of matched Kubernetes clusters. Each element contains the following attributes:
    id string
    The provider-assigned unique ID for this managed resource.
    ids string[]
    A list of matched Kubernetes clusters' ids.
    names string[]
    A list of matched Kubernetes clusters' names.
    enableDetails boolean
    nameRegex string
    outputFile string
    clusters Sequence[GetEdgeKubernetesClustersCluster]
    A list of matched Kubernetes clusters. Each element contains the following attributes:
    id str
    The provider-assigned unique ID for this managed resource.
    ids Sequence[str]
    A list of matched Kubernetes clusters' ids.
    names Sequence[str]
    A list of matched Kubernetes clusters' names.
    enable_details bool
    name_regex str
    output_file str
    clusters List<Property Map>
    A list of matched Kubernetes clusters. Each element contains the following attributes:
    id String
    The provider-assigned unique ID for this managed resource.
    ids List<String>
    A list of matched Kubernetes clusters' ids.
    names List<String>
    A list of matched Kubernetes clusters' names.
    enableDetails Boolean
    nameRegex String
    outputFile String

    Supporting Types

    GetEdgeKubernetesClustersCluster

    AvailabilityZone string
    The ID of availability zone.
    Connections Pulumi.AliCloud.CS.Inputs.GetEdgeKubernetesClustersClusterConnections
    Map of kubernetes cluster connection information. It contains several attributes to Block Connections.
    Id string
    ID of the node.
    Name string
    Node name.
    NatGatewayId string
    The ID of nat gateway used to launch kubernetes cluster.
    SecurityGroupId string
    The ID of security group where the current cluster worker node is located.
    VpcId string
    The ID of VPC where the current cluster is located.
    WorkerNodes List<Pulumi.AliCloud.CS.Inputs.GetEdgeKubernetesClustersClusterWorkerNode>
    List of cluster worker nodes. It contains several attributes to Block Nodes.
    AvailabilityZone string
    The ID of availability zone.
    Connections GetEdgeKubernetesClustersClusterConnections
    Map of kubernetes cluster connection information. It contains several attributes to Block Connections.
    Id string
    ID of the node.
    Name string
    Node name.
    NatGatewayId string
    The ID of nat gateway used to launch kubernetes cluster.
    SecurityGroupId string
    The ID of security group where the current cluster worker node is located.
    VpcId string
    The ID of VPC where the current cluster is located.
    WorkerNodes []GetEdgeKubernetesClustersClusterWorkerNode
    List of cluster worker nodes. It contains several attributes to Block Nodes.
    availabilityZone String
    The ID of availability zone.
    connections GetEdgeKubernetesClustersClusterConnections
    Map of kubernetes cluster connection information. It contains several attributes to Block Connections.
    id String
    ID of the node.
    name String
    Node name.
    natGatewayId String
    The ID of nat gateway used to launch kubernetes cluster.
    securityGroupId String
    The ID of security group where the current cluster worker node is located.
    vpcId String
    The ID of VPC where the current cluster is located.
    workerNodes List<GetEdgeKubernetesClustersClusterWorkerNode>
    List of cluster worker nodes. It contains several attributes to Block Nodes.
    availabilityZone string
    The ID of availability zone.
    connections GetEdgeKubernetesClustersClusterConnections
    Map of kubernetes cluster connection information. It contains several attributes to Block Connections.
    id string
    ID of the node.
    name string
    Node name.
    natGatewayId string
    The ID of nat gateway used to launch kubernetes cluster.
    securityGroupId string
    The ID of security group where the current cluster worker node is located.
    vpcId string
    The ID of VPC where the current cluster is located.
    workerNodes GetEdgeKubernetesClustersClusterWorkerNode[]
    List of cluster worker nodes. It contains several attributes to Block Nodes.
    availability_zone str
    The ID of availability zone.
    connections GetEdgeKubernetesClustersClusterConnections
    Map of kubernetes cluster connection information. It contains several attributes to Block Connections.
    id str
    ID of the node.
    name str
    Node name.
    nat_gateway_id str
    The ID of nat gateway used to launch kubernetes cluster.
    security_group_id str
    The ID of security group where the current cluster worker node is located.
    vpc_id str
    The ID of VPC where the current cluster is located.
    worker_nodes Sequence[GetEdgeKubernetesClustersClusterWorkerNode]
    List of cluster worker nodes. It contains several attributes to Block Nodes.
    availabilityZone String
    The ID of availability zone.
    connections Property Map
    Map of kubernetes cluster connection information. It contains several attributes to Block Connections.
    id String
    ID of the node.
    name String
    Node name.
    natGatewayId String
    The ID of nat gateway used to launch kubernetes cluster.
    securityGroupId String
    The ID of security group where the current cluster worker node is located.
    vpcId String
    The ID of VPC where the current cluster is located.
    workerNodes List<Property Map>
    List of cluster worker nodes. It contains several attributes to Block Nodes.

    GetEdgeKubernetesClustersClusterConnections

    ApiServerInternet string
    API Server Internet endpoint.
    ApiServerIntranet string
    API Server Intranet endpoint.
    ApiServerInternet string
    API Server Internet endpoint.
    ApiServerIntranet string
    API Server Intranet endpoint.
    apiServerInternet String
    API Server Internet endpoint.
    apiServerIntranet String
    API Server Intranet endpoint.
    apiServerInternet string
    API Server Internet endpoint.
    apiServerIntranet string
    API Server Intranet endpoint.
    api_server_internet str
    API Server Internet endpoint.
    api_server_intranet str
    API Server Intranet endpoint.
    apiServerInternet String
    API Server Internet endpoint.
    apiServerIntranet String
    API Server Intranet endpoint.

    GetEdgeKubernetesClustersClusterWorkerNode

    Id string
    ID of the node.
    Name string
    Node name.
    PrivateIp string
    The private IP address of node.
    Id string
    ID of the node.
    Name string
    Node name.
    PrivateIp string
    The private IP address of node.
    id String
    ID of the node.
    name String
    Node name.
    privateIp String
    The private IP address of node.
    id string
    ID of the node.
    name string
    Node name.
    privateIp string
    The private IP address of node.
    id str
    ID of the node.
    name str
    Node name.
    private_ip str
    The private IP address of node.
    id String
    ID of the node.
    name String
    Node name.
    privateIp String
    The private IP address of node.

    Package Details

    Repository
    Alibaba Cloud pulumi/pulumi-alicloud
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the alicloud Terraform Provider.
    alicloud logo
    Alibaba Cloud v3.51.0 published on Saturday, Mar 23, 2024 by Pulumi