Viewing docs for Vultr v2.27.1
published on Tuesday, Sep 30, 2025 by dirien
published on Tuesday, Sep 30, 2025 by dirien
Viewing docs for Vultr v2.27.1
published on Tuesday, Sep 30, 2025 by dirien
published on Tuesday, Sep 30, 2025 by dirien
Get information about a Vultr load balancer.
Example Usage
Get the information for a load balancer by label:
import * as pulumi from "@pulumi/pulumi";
import * as vultr from "@ediri/vultr";
const myLb = vultr.getLoadBalancer({
filters: [{
name: "label",
values: ["my-lb-label"],
}],
});
import pulumi
import pulumi_vultr as vultr
my_lb = vultr.get_load_balancer(filters=[{
"name": "label",
"values": ["my-lb-label"],
}])
package main
import (
"github.com/dirien/pulumi-vultr/sdk/v2/go/vultr"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := vultr.LookupLoadBalancer(ctx, &vultr.LookupLoadBalancerArgs{
Filters: []vultr.GetLoadBalancerFilter{
{
Name: "label",
Values: []string{
"my-lb-label",
},
},
},
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Vultr = Pulumi.Vultr;
return await Deployment.RunAsync(() =>
{
var myLb = Vultr.GetLoadBalancer.Invoke(new()
{
Filters = new[]
{
new Vultr.Inputs.GetLoadBalancerFilterInputArgs
{
Name = "label",
Values = new[]
{
"my-lb-label",
},
},
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.vultr.VultrFunctions;
import com.pulumi.vultr.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 myLb = VultrFunctions.getLoadBalancer(GetLoadBalancerArgs.builder()
.filters(GetLoadBalancerFilterArgs.builder()
.name("label")
.values("my-lb-label")
.build())
.build());
}
}
variables:
myLb:
fn::invoke:
function: vultr:getLoadBalancer
arguments:
filters:
- name: label
values:
- my-lb-label
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(filters: Optional[Sequence[GetLoadBalancerFilter]] = None,
proxy_protocol: Optional[bool] = None,
opts: Optional[InvokeOptions] = None) -> GetLoadBalancerResult
def get_load_balancer_output(filters: Optional[pulumi.Input[Sequence[pulumi.Input[GetLoadBalancerFilterArgs]]]] = None,
proxy_protocol: Optional[pulumi.Input[bool]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetLoadBalancerResult]func LookupLoadBalancer(ctx *Context, args *LookupLoadBalancerArgs, opts ...InvokeOption) (*LookupLoadBalancerResult, error)
func LookupLoadBalancerOutput(ctx *Context, args *LookupLoadBalancerOutputArgs, opts ...InvokeOption) LookupLoadBalancerResultOutput> Note: This function is named LookupLoadBalancer 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)
public static Output<GetLoadBalancerResult> getLoadBalancer(GetLoadBalancerArgs args, InvokeOptions options)
fn::invoke:
function: vultr:index/getLoadBalancer:getLoadBalancer
arguments:
# arguments dictionaryThe following arguments are supported:
- Filters
List<ediri.
Vultr. Inputs. Get Load Balancer Filter> - Query parameters for finding load balancers.
- Proxy
Protocol bool - Boolean value that indicates if Proxy Protocol is enabled.
- Filters
[]Get
Load Balancer Filter - Query parameters for finding load balancers.
- Proxy
Protocol bool - Boolean value that indicates if Proxy Protocol is enabled.
- filters
List<Get
Load Balancer Filter> - Query parameters for finding load balancers.
- proxy
Protocol Boolean - Boolean value that indicates if Proxy Protocol is enabled.
- filters
Get
Load Balancer Filter[] - Query parameters for finding load balancers.
- proxy
Protocol boolean - Boolean value that indicates if Proxy Protocol is enabled.
- filters
Sequence[Get
Load Balancer Filter] - Query parameters for finding load balancers.
- proxy_
protocol bool - Boolean value that indicates if Proxy Protocol is enabled.
- filters List<Property Map>
- Query parameters for finding load balancers.
- proxy
Protocol Boolean - Boolean value that indicates if Proxy Protocol is enabled.
getLoadBalancer Result
The following output properties are available:
- Attached
Instances List<string> - Array of instances that are currently attached to the load balancer.
- Balancing
Algorithm string - The balancing algorithm for your load balancer.
- string
- Name for your given sticky session.
- Date
Created string - Firewall
Rules List<ImmutableDictionary<string, string>> - Forwarding
Rules List<ImmutableDictionary<string, string>> - Defines the forwarding rules for a load balancer. The configuration of a
forwarding_rulesis listened below. - Has
Ssl bool - Boolean value that indicates if SSL is enabled.
- Health
Check Dictionary<string, string> - Defines the way load balancers should check for health. The configuration of a
health_checkis listed below. - Id string
- The provider-assigned unique ID for this managed resource.
- Ipv4 string
- IPv4 address for your load balancer.
- Ipv6 string
- IPv6 address for your load balancer.
- Label string
- The load balancers label.
- Region string
- The region your load balancer is deployed in.
- Ssl Dictionary<string, string>
- Ssl
Redirect bool - Boolean value that indicates if HTTP calls will be redirected to HTTPS.
- Status string
- Current status for the load balancer
- Filters
List<ediri.
Vultr. Outputs. Get Load Balancer Filter> - Proxy
Protocol bool - Boolean value that indicates if Proxy Protocol is enabled.
- Attached
Instances []string - Array of instances that are currently attached to the load balancer.
- Balancing
Algorithm string - The balancing algorithm for your load balancer.
- string
- Name for your given sticky session.
- Date
Created string - Firewall
Rules []map[string]string - Forwarding
Rules []map[string]string - Defines the forwarding rules for a load balancer. The configuration of a
forwarding_rulesis listened below. - Has
Ssl bool - Boolean value that indicates if SSL is enabled.
- Health
Check map[string]string - Defines the way load balancers should check for health. The configuration of a
health_checkis listed below. - Id string
- The provider-assigned unique ID for this managed resource.
- Ipv4 string
- IPv4 address for your load balancer.
- Ipv6 string
- IPv6 address for your load balancer.
- Label string
- The load balancers label.
- Region string
- The region your load balancer is deployed in.
- Ssl map[string]string
- Ssl
Redirect bool - Boolean value that indicates if HTTP calls will be redirected to HTTPS.
- Status string
- Current status for the load balancer
- Filters
[]Get
Load Balancer Filter - Proxy
Protocol bool - Boolean value that indicates if Proxy Protocol is enabled.
- attached
Instances List<String> - Array of instances that are currently attached to the load balancer.
- balancing
Algorithm String - The balancing algorithm for your load balancer.
- String
- Name for your given sticky session.
- date
Created String - firewall
Rules List<Map<String,String>> - forwarding
Rules List<Map<String,String>> - Defines the forwarding rules for a load balancer. The configuration of a
forwarding_rulesis listened below. - has
Ssl Boolean - Boolean value that indicates if SSL is enabled.
- health
Check Map<String,String> - Defines the way load balancers should check for health. The configuration of a
health_checkis listed below. - id String
- The provider-assigned unique ID for this managed resource.
- ipv4 String
- IPv4 address for your load balancer.
- ipv6 String
- IPv6 address for your load balancer.
- label String
- The load balancers label.
- region String
- The region your load balancer is deployed in.
- ssl Map<String,String>
- ssl
Redirect Boolean - Boolean value that indicates if HTTP calls will be redirected to HTTPS.
- status String
- Current status for the load balancer
- filters
List<Get
Load Balancer Filter> - proxy
Protocol Boolean - Boolean value that indicates if Proxy Protocol is enabled.
- attached
Instances string[] - Array of instances that are currently attached to the load balancer.
- balancing
Algorithm string - The balancing algorithm for your load balancer.
- string
- Name for your given sticky session.
- date
Created string - firewall
Rules {[key: string]: string}[] - forwarding
Rules {[key: string]: string}[] - Defines the forwarding rules for a load balancer. The configuration of a
forwarding_rulesis listened below. - has
Ssl boolean - Boolean value that indicates if SSL is enabled.
- health
Check {[key: string]: string} - Defines the way load balancers should check for health. The configuration of a
health_checkis listed below. - id string
- The provider-assigned unique ID for this managed resource.
- ipv4 string
- IPv4 address for your load balancer.
- ipv6 string
- IPv6 address for your load balancer.
- label string
- The load balancers label.
- region string
- The region your load balancer is deployed in.
- ssl {[key: string]: string}
- ssl
Redirect boolean - Boolean value that indicates if HTTP calls will be redirected to HTTPS.
- status string
- Current status for the load balancer
- filters
Get
Load Balancer Filter[] - proxy
Protocol boolean - Boolean value that indicates if Proxy Protocol is enabled.
- attached_
instances Sequence[str] - Array of instances that are currently attached to the load balancer.
- balancing_
algorithm str - The balancing algorithm for your load balancer.
- str
- Name for your given sticky session.
- date_
created str - firewall_
rules Sequence[Mapping[str, str]] - forwarding_
rules Sequence[Mapping[str, str]] - Defines the forwarding rules for a load balancer. The configuration of a
forwarding_rulesis listened below. - has_
ssl bool - Boolean value that indicates if SSL is enabled.
- health_
check Mapping[str, str] - Defines the way load balancers should check for health. The configuration of a
health_checkis listed below. - id str
- The provider-assigned unique ID for this managed resource.
- ipv4 str
- IPv4 address for your load balancer.
- ipv6 str
- IPv6 address for your load balancer.
- label str
- The load balancers label.
- region str
- The region your load balancer is deployed in.
- ssl Mapping[str, str]
- ssl_
redirect bool - Boolean value that indicates if HTTP calls will be redirected to HTTPS.
- status str
- Current status for the load balancer
- filters
Sequence[Get
Load Balancer Filter] - proxy_
protocol bool - Boolean value that indicates if Proxy Protocol is enabled.
- attached
Instances List<String> - Array of instances that are currently attached to the load balancer.
- balancing
Algorithm String - The balancing algorithm for your load balancer.
- String
- Name for your given sticky session.
- date
Created String - firewall
Rules List<Map<String>> - forwarding
Rules List<Map<String>> - Defines the forwarding rules for a load balancer. The configuration of a
forwarding_rulesis listened below. - has
Ssl Boolean - Boolean value that indicates if SSL is enabled.
- health
Check Map<String> - Defines the way load balancers should check for health. The configuration of a
health_checkis listed below. - id String
- The provider-assigned unique ID for this managed resource.
- ipv4 String
- IPv4 address for your load balancer.
- ipv6 String
- IPv6 address for your load balancer.
- label String
- The load balancers label.
- region String
- The region your load balancer is deployed in.
- ssl Map<String>
- ssl
Redirect Boolean - Boolean value that indicates if HTTP calls will be redirected to HTTPS.
- status String
- Current status for the load balancer
- filters List<Property Map>
- proxy
Protocol Boolean - Boolean value that indicates if Proxy Protocol is enabled.
Supporting Types
GetLoadBalancerFilter
Package Details
- Repository
- vultr dirien/pulumi-vultr
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
vultrTerraform Provider.
Viewing docs for Vultr v2.27.1
published on Tuesday, Sep 30, 2025 by dirien
published on Tuesday, Sep 30, 2025 by dirien
