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

ovh.CloudProject.getLoadBalancer

Explore with Pulumi AI

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

    Get the details of a public cloud project loadbalancer.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as ovh from "@pulumi/ovh";
    
    const lbLoadBalancer = ovh.CloudProject.getLoadBalancer({
        serviceName: "XXXXXX",
        regionName: "XXX",
        id: "XXX",
    });
    export const lb = lbLoadBalancer;
    
    import pulumi
    import pulumi_ovh as ovh
    
    lb_load_balancer = ovh.CloudProject.get_load_balancer(service_name="XXXXXX",
        region_name="XXX",
        id="XXX")
    pulumi.export("lb", lb_load_balancer)
    
    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 {
    		lbLoadBalancer, err := CloudProject.GetLoadBalancer(ctx, &cloudproject.GetLoadBalancerArgs{
    			ServiceName: "XXXXXX",
    			RegionName:  "XXX",
    			Id:          "XXX",
    		}, nil)
    		if err != nil {
    			return err
    		}
    		ctx.Export("lb", lbLoadBalancer)
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Ovh = Pulumi.Ovh;
    
    return await Deployment.RunAsync(() => 
    {
        var lbLoadBalancer = Ovh.CloudProject.GetLoadBalancer.Invoke(new()
        {
            ServiceName = "XXXXXX",
            RegionName = "XXX",
            Id = "XXX",
        });
    
        return new Dictionary<string, object?>
        {
            ["lb"] = lbLoadBalancer,
        };
    });
    
    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.GetLoadBalancerArgs;
    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 lbLoadBalancer = CloudProjectFunctions.getLoadBalancer(GetLoadBalancerArgs.builder()
                .serviceName("XXXXXX")
                .regionName("XXX")
                .id("XXX")
                .build());
    
            ctx.export("lb", lbLoadBalancer.applyValue(getLoadBalancerResult -> getLoadBalancerResult));
        }
    }
    
    variables:
      lbLoadBalancer:
        fn::invoke:
          Function: ovh:CloudProject:getLoadBalancer
          Arguments:
            serviceName: XXXXXX
            regionName: XXX
            id: XXX
    outputs:
      lb: ${lbLoadBalancer}
    

    Using getLoadBalancer

    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 getLoadBalancer(args: GetLoadBalancerArgs, opts?: InvokeOptions): Promise<GetLoadBalancerResult>
    function getLoadBalancerOutput(args: GetLoadBalancerOutputArgs, opts?: InvokeOptions): Output<GetLoadBalancerResult>
    def get_load_balancer(id: Optional[str] = None,
                          region_name: Optional[str] = None,
                          service_name: Optional[str] = None,
                          opts: Optional[InvokeOptions] = None) -> GetLoadBalancerResult
    def get_load_balancer_output(id: Optional[pulumi.Input[str]] = None,
                          region_name: Optional[pulumi.Input[str]] = None,
                          service_name: Optional[pulumi.Input[str]] = None,
                          opts: Optional[InvokeOptions] = None) -> Output[GetLoadBalancerResult]
    func GetLoadBalancer(ctx *Context, args *GetLoadBalancerArgs, opts ...InvokeOption) (*GetLoadBalancerResult, error)
    func GetLoadBalancerOutput(ctx *Context, args *GetLoadBalancerOutputArgs, opts ...InvokeOption) GetLoadBalancerResultOutput

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

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

    The following arguments are supported:

    Id string
    ID of the loadbalancer
    RegionName string
    Region of the loadbalancer.
    ServiceName string
    The ID of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    Id string
    ID of the loadbalancer
    RegionName string
    Region of the loadbalancer.
    ServiceName string
    The ID of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    id String
    ID of the loadbalancer
    regionName String
    Region of the loadbalancer.
    serviceName String
    The ID of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    id string
    ID of the loadbalancer
    regionName string
    Region of the loadbalancer.
    serviceName string
    The ID of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    id str
    ID of the loadbalancer
    region_name str
    Region of the loadbalancer.
    service_name str
    The ID of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.
    id String
    ID of the loadbalancer
    regionName String
    Region of the loadbalancer.
    serviceName String
    The ID of the public cloud project. If omitted, the OVH_CLOUD_PROJECT_SERVICE environment variable is used.

    getLoadBalancer Result

    The following output properties are available:

    CreatedAt string
    Date of creation of the loadbalancer
    FlavorId string
    ID of the flavor
    FloatingIp GetLoadBalancerFloatingIp
    Information about the floating IP
    Id string
    ID of the floating IP
    Name string
    Name of the loadbalancer
    OperatingStatus string
    Operating status of the loadbalancer
    ProvisioningStatus string
    Provisioning status of the loadbalancer
    RegionName string
    Region of the loadbalancer
    ServiceName string
    ID of the public cloud project
    UpdatedAt string
    Last update date of the loadbalancer
    VipAddress string
    IP address of the Virtual IP
    VipNetworkId string
    Openstack ID of the network for the Virtual IP
    VipSubnetId string
    ID of the subnet for the Virtual IP
    CreatedAt string
    Date of creation of the loadbalancer
    FlavorId string
    ID of the flavor
    FloatingIp GetLoadBalancerFloatingIp
    Information about the floating IP
    Id string
    ID of the floating IP
    Name string
    Name of the loadbalancer
    OperatingStatus string
    Operating status of the loadbalancer
    ProvisioningStatus string
    Provisioning status of the loadbalancer
    RegionName string
    Region of the loadbalancer
    ServiceName string
    ID of the public cloud project
    UpdatedAt string
    Last update date of the loadbalancer
    VipAddress string
    IP address of the Virtual IP
    VipNetworkId string
    Openstack ID of the network for the Virtual IP
    VipSubnetId string
    ID of the subnet for the Virtual IP
    createdAt String
    Date of creation of the loadbalancer
    flavorId String
    ID of the flavor
    floatingIp GetLoadBalancerFloatingIp
    Information about the floating IP
    id String
    ID of the floating IP
    name String
    Name of the loadbalancer
    operatingStatus String
    Operating status of the loadbalancer
    provisioningStatus String
    Provisioning status of the loadbalancer
    regionName String
    Region of the loadbalancer
    serviceName String
    ID of the public cloud project
    updatedAt String
    Last update date of the loadbalancer
    vipAddress String
    IP address of the Virtual IP
    vipNetworkId String
    Openstack ID of the network for the Virtual IP
    vipSubnetId String
    ID of the subnet for the Virtual IP
    createdAt string
    Date of creation of the loadbalancer
    flavorId string
    ID of the flavor
    floatingIp GetLoadBalancerFloatingIp
    Information about the floating IP
    id string
    ID of the floating IP
    name string
    Name of the loadbalancer
    operatingStatus string
    Operating status of the loadbalancer
    provisioningStatus string
    Provisioning status of the loadbalancer
    regionName string
    Region of the loadbalancer
    serviceName string
    ID of the public cloud project
    updatedAt string
    Last update date of the loadbalancer
    vipAddress string
    IP address of the Virtual IP
    vipNetworkId string
    Openstack ID of the network for the Virtual IP
    vipSubnetId string
    ID of the subnet for the Virtual IP
    created_at str
    Date of creation of the loadbalancer
    flavor_id str
    ID of the flavor
    floating_ip cloudproject.GetLoadBalancerFloatingIp
    Information about the floating IP
    id str
    ID of the floating IP
    name str
    Name of the loadbalancer
    operating_status str
    Operating status of the loadbalancer
    provisioning_status str
    Provisioning status of the loadbalancer
    region_name str
    Region of the loadbalancer
    service_name str
    ID of the public cloud project
    updated_at str
    Last update date of the loadbalancer
    vip_address str
    IP address of the Virtual IP
    vip_network_id str
    Openstack ID of the network for the Virtual IP
    vip_subnet_id str
    ID of the subnet for the Virtual IP
    createdAt String
    Date of creation of the loadbalancer
    flavorId String
    ID of the flavor
    floatingIp Property Map
    Information about the floating IP
    id String
    ID of the floating IP
    name String
    Name of the loadbalancer
    operatingStatus String
    Operating status of the loadbalancer
    provisioningStatus String
    Provisioning status of the loadbalancer
    regionName String
    Region of the loadbalancer
    serviceName String
    ID of the public cloud project
    updatedAt String
    Last update date of the loadbalancer
    vipAddress String
    IP address of the Virtual IP
    vipNetworkId String
    Openstack ID of the network for the Virtual IP
    vipSubnetId String
    ID of the subnet for the Virtual IP

    Supporting Types

    GetLoadBalancerFloatingIp

    Id string
    ID of the loadbalancer
    Ip string
    Value of the floating IP
    Id string
    ID of the loadbalancer
    Ip string
    Value of the floating IP
    id String
    ID of the loadbalancer
    ip String
    Value of the floating IP
    id string
    ID of the loadbalancer
    ip string
    Value of the floating IP
    id str
    ID of the loadbalancer
    ip str
    Value of the floating IP
    id String
    ID of the loadbalancer
    ip String
    Value of the floating IP

    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