gcore 0.22.0 published on Wednesday, Apr 30, 2025 by g-core
gcore.getLbpool
Explore with Pulumi AI
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as gcore from "@pulumi/gcore";
const project = gcore.getProject({
name: "Default",
});
const region = gcore.getRegion({
name: "Luxembourg-2",
});
const pool = Promise.all([region, project]).then(([region, project]) => gcore.getLbpool({
regionId: region.id,
projectId: project.id,
name: "test-pool",
}));
export const view = pool;
import pulumi
import pulumi_gcore as gcore
project = gcore.get_project(name="Default")
region = gcore.get_region(name="Luxembourg-2")
pool = gcore.get_lbpool(region_id=region.id,
project_id=project.id,
name="test-pool")
pulumi.export("view", pool)
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/gcore/gcore"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
project, err := gcore.GetProject(ctx, &gcore.GetProjectArgs{
Name: "Default",
}, nil)
if err != nil {
return err
}
region, err := gcore.GetRegion(ctx, &gcore.GetRegionArgs{
Name: "Luxembourg-2",
}, nil)
if err != nil {
return err
}
pool, err := gcore.LookupLbpool(ctx, &gcore.LookupLbpoolArgs{
RegionId: pulumi.Float64Ref(region.Id),
ProjectId: pulumi.Float64Ref(project.Id),
Name: "test-pool",
}, nil)
if err != nil {
return err
}
ctx.Export("view", pool)
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Gcore = Pulumi.Gcore;
return await Deployment.RunAsync(() =>
{
var project = Gcore.GetProject.Invoke(new()
{
Name = "Default",
});
var region = Gcore.GetRegion.Invoke(new()
{
Name = "Luxembourg-2",
});
var pool = Gcore.GetLbpool.Invoke(new()
{
RegionId = region.Apply(getRegionResult => getRegionResult.Id),
ProjectId = project.Apply(getProjectResult => getProjectResult.Id),
Name = "test-pool",
});
return new Dictionary<string, object?>
{
["view"] = pool,
};
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.gcore.GcoreFunctions;
import com.pulumi.gcore.inputs.GetProjectArgs;
import com.pulumi.gcore.inputs.GetRegionArgs;
import com.pulumi.gcore.inputs.GetLbpoolArgs;
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 project = GcoreFunctions.getProject(GetProjectArgs.builder()
.name("Default")
.build());
final var region = GcoreFunctions.getRegion(GetRegionArgs.builder()
.name("Luxembourg-2")
.build());
final var pool = GcoreFunctions.getLbpool(GetLbpoolArgs.builder()
.regionId(region.applyValue(getRegionResult -> getRegionResult.id()))
.projectId(project.applyValue(getProjectResult -> getProjectResult.id()))
.name("test-pool")
.build());
ctx.export("view", pool.applyValue(getLbpoolResult -> getLbpoolResult));
}
}
variables:
project:
fn::invoke:
function: gcore:getProject
arguments:
name: Default
region:
fn::invoke:
function: gcore:getRegion
arguments:
name: Luxembourg-2
pool:
fn::invoke:
function: gcore:getLbpool
arguments:
regionId: ${region.id}
projectId: ${project.id}
name: test-pool
outputs:
view: ${pool}
Using getLbpool
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 getLbpool(args: GetLbpoolArgs, opts?: InvokeOptions): Promise<GetLbpoolResult>
function getLbpoolOutput(args: GetLbpoolOutputArgs, opts?: InvokeOptions): Output<GetLbpoolResult>
def get_lbpool(id: Optional[str] = None,
listener_id: Optional[str] = None,
loadbalancer_id: Optional[str] = None,
name: Optional[str] = None,
project_id: Optional[float] = None,
project_name: Optional[str] = None,
region_id: Optional[float] = None,
region_name: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetLbpoolResult
def get_lbpool_output(id: Optional[pulumi.Input[str]] = None,
listener_id: Optional[pulumi.Input[str]] = None,
loadbalancer_id: Optional[pulumi.Input[str]] = None,
name: Optional[pulumi.Input[str]] = None,
project_id: Optional[pulumi.Input[float]] = None,
project_name: Optional[pulumi.Input[str]] = None,
region_id: Optional[pulumi.Input[float]] = None,
region_name: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetLbpoolResult]
func LookupLbpool(ctx *Context, args *LookupLbpoolArgs, opts ...InvokeOption) (*LookupLbpoolResult, error)
func LookupLbpoolOutput(ctx *Context, args *LookupLbpoolOutputArgs, opts ...InvokeOption) LookupLbpoolResultOutput
> Note: This function is named LookupLbpool
in the Go SDK.
public static class GetLbpool
{
public static Task<GetLbpoolResult> InvokeAsync(GetLbpoolArgs args, InvokeOptions? opts = null)
public static Output<GetLbpoolResult> Invoke(GetLbpoolInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetLbpoolResult> getLbpool(GetLbpoolArgs args, InvokeOptions options)
public static Output<GetLbpoolResult> getLbpool(GetLbpoolArgs args, InvokeOptions options)
fn::invoke:
function: gcore:index/getLbpool:getLbpool
arguments:
# arguments dictionary
The following arguments are supported:
- Name string
- Name of the load balancer pool.
- Id string
- The ID of this resource.
- Listener
Id string - ID of the load balancer listener to which pool was attached.
- Loadbalancer
Id string - ID of the load balancer to which pool was attached.
- Project
Id double - ID of the project in which load balancer pool was created.
- Project
Name string - Name of the project in which load balancer pool was created.
- Region
Id double - ID of the region in which load balancer pool was created.
- Region
Name string - Name of the region in which load balancer pool was created.
- Name string
- Name of the load balancer pool.
- Id string
- The ID of this resource.
- Listener
Id string - ID of the load balancer listener to which pool was attached.
- Loadbalancer
Id string - ID of the load balancer to which pool was attached.
- Project
Id float64 - ID of the project in which load balancer pool was created.
- Project
Name string - Name of the project in which load balancer pool was created.
- Region
Id float64 - ID of the region in which load balancer pool was created.
- Region
Name string - Name of the region in which load balancer pool was created.
- name String
- Name of the load balancer pool.
- id String
- The ID of this resource.
- listener
Id String - ID of the load balancer listener to which pool was attached.
- loadbalancer
Id String - ID of the load balancer to which pool was attached.
- project
Id Double - ID of the project in which load balancer pool was created.
- project
Name String - Name of the project in which load balancer pool was created.
- region
Id Double - ID of the region in which load balancer pool was created.
- region
Name String - Name of the region in which load balancer pool was created.
- name string
- Name of the load balancer pool.
- id string
- The ID of this resource.
- listener
Id string - ID of the load balancer listener to which pool was attached.
- loadbalancer
Id string - ID of the load balancer to which pool was attached.
- project
Id number - ID of the project in which load balancer pool was created.
- project
Name string - Name of the project in which load balancer pool was created.
- region
Id number - ID of the region in which load balancer pool was created.
- region
Name string - Name of the region in which load balancer pool was created.
- name str
- Name of the load balancer pool.
- id str
- The ID of this resource.
- listener_
id str - ID of the load balancer listener to which pool was attached.
- loadbalancer_
id str - ID of the load balancer to which pool was attached.
- project_
id float - ID of the project in which load balancer pool was created.
- project_
name str - Name of the project in which load balancer pool was created.
- region_
id float - ID of the region in which load balancer pool was created.
- region_
name str - Name of the region in which load balancer pool was created.
- name String
- Name of the load balancer pool.
- id String
- The ID of this resource.
- listener
Id String - ID of the load balancer listener to which pool was attached.
- loadbalancer
Id String - ID of the load balancer to which pool was attached.
- project
Id Number - ID of the project in which load balancer pool was created.
- project
Name String - Name of the project in which load balancer pool was created.
- region
Id Number - ID of the region in which load balancer pool was created.
- region
Name String - Name of the region in which load balancer pool was created.
getLbpool Result
The following output properties are available:
- Health
Monitors List<GetLbpool Health Monitor> - Health Monitor settings for defining health state of members inside this pool.
- Id string
- The ID of this resource.
- Lb
Algorithm string - Available values is 'ROUNDROBIN', 'LEASTCONNECTIONS', 'SOURCE_IP'
- Listener
Id string - ID of the load balancer listener to which pool was attached.
- Loadbalancer
Id string - ID of the load balancer to which pool was attached.
- Name string
- Name of the load balancer pool.
- Protocol string
- Available values are 'HTTP', 'HTTPS', 'TCP', 'UDP', 'PROXY', 'PROXYV2'
- Session
Persistences List<GetLbpool Session Persistence> - Pool session persistence tells the load balancer to attempt to send future requests from a client to the same backend member as the initial request.
- Project
Id double - ID of the project in which load balancer pool was created.
- Project
Name string - Name of the project in which load balancer pool was created.
- Region
Id double - ID of the region in which load balancer pool was created.
- Region
Name string - Name of the region in which load balancer pool was created.
- Health
Monitors []GetLbpool Health Monitor - Health Monitor settings for defining health state of members inside this pool.
- Id string
- The ID of this resource.
- Lb
Algorithm string - Available values is 'ROUNDROBIN', 'LEASTCONNECTIONS', 'SOURCE_IP'
- Listener
Id string - ID of the load balancer listener to which pool was attached.
- Loadbalancer
Id string - ID of the load balancer to which pool was attached.
- Name string
- Name of the load balancer pool.
- Protocol string
- Available values are 'HTTP', 'HTTPS', 'TCP', 'UDP', 'PROXY', 'PROXYV2'
- Session
Persistences []GetLbpool Session Persistence - Pool session persistence tells the load balancer to attempt to send future requests from a client to the same backend member as the initial request.
- Project
Id float64 - ID of the project in which load balancer pool was created.
- Project
Name string - Name of the project in which load balancer pool was created.
- Region
Id float64 - ID of the region in which load balancer pool was created.
- Region
Name string - Name of the region in which load balancer pool was created.
- health
Monitors List<GetLbpool Health Monitor> - Health Monitor settings for defining health state of members inside this pool.
- id String
- The ID of this resource.
- lb
Algorithm String - Available values is 'ROUNDROBIN', 'LEASTCONNECTIONS', 'SOURCE_IP'
- listener
Id String - ID of the load balancer listener to which pool was attached.
- loadbalancer
Id String - ID of the load balancer to which pool was attached.
- name String
- Name of the load balancer pool.
- protocol String
- Available values are 'HTTP', 'HTTPS', 'TCP', 'UDP', 'PROXY', 'PROXYV2'
- session
Persistences List<GetLbpool Session Persistence> - Pool session persistence tells the load balancer to attempt to send future requests from a client to the same backend member as the initial request.
- project
Id Double - ID of the project in which load balancer pool was created.
- project
Name String - Name of the project in which load balancer pool was created.
- region
Id Double - ID of the region in which load balancer pool was created.
- region
Name String - Name of the region in which load balancer pool was created.
- health
Monitors GetLbpool Health Monitor[] - Health Monitor settings for defining health state of members inside this pool.
- id string
- The ID of this resource.
- lb
Algorithm string - Available values is 'ROUNDROBIN', 'LEASTCONNECTIONS', 'SOURCE_IP'
- listener
Id string - ID of the load balancer listener to which pool was attached.
- loadbalancer
Id string - ID of the load balancer to which pool was attached.
- name string
- Name of the load balancer pool.
- protocol string
- Available values are 'HTTP', 'HTTPS', 'TCP', 'UDP', 'PROXY', 'PROXYV2'
- session
Persistences GetLbpool Session Persistence[] - Pool session persistence tells the load balancer to attempt to send future requests from a client to the same backend member as the initial request.
- project
Id number - ID of the project in which load balancer pool was created.
- project
Name string - Name of the project in which load balancer pool was created.
- region
Id number - ID of the region in which load balancer pool was created.
- region
Name string - Name of the region in which load balancer pool was created.
- health_
monitors Sequence[GetLbpool Health Monitor] - Health Monitor settings for defining health state of members inside this pool.
- id str
- The ID of this resource.
- lb_
algorithm str - Available values is 'ROUNDROBIN', 'LEASTCONNECTIONS', 'SOURCE_IP'
- listener_
id str - ID of the load balancer listener to which pool was attached.
- loadbalancer_
id str - ID of the load balancer to which pool was attached.
- name str
- Name of the load balancer pool.
- protocol str
- Available values are 'HTTP', 'HTTPS', 'TCP', 'UDP', 'PROXY', 'PROXYV2'
- session_
persistences Sequence[GetLbpool Session Persistence] - Pool session persistence tells the load balancer to attempt to send future requests from a client to the same backend member as the initial request.
- project_
id float - ID of the project in which load balancer pool was created.
- project_
name str - Name of the project in which load balancer pool was created.
- region_
id float - ID of the region in which load balancer pool was created.
- region_
name str - Name of the region in which load balancer pool was created.
- health
Monitors List<Property Map> - Health Monitor settings for defining health state of members inside this pool.
- id String
- The ID of this resource.
- lb
Algorithm String - Available values is 'ROUNDROBIN', 'LEASTCONNECTIONS', 'SOURCE_IP'
- listener
Id String - ID of the load balancer listener to which pool was attached.
- loadbalancer
Id String - ID of the load balancer to which pool was attached.
- name String
- Name of the load balancer pool.
- protocol String
- Available values are 'HTTP', 'HTTPS', 'TCP', 'UDP', 'PROXY', 'PROXYV2'
- session
Persistences List<Property Map> - Pool session persistence tells the load balancer to attempt to send future requests from a client to the same backend member as the initial request.
- project
Id Number - ID of the project in which load balancer pool was created.
- project
Name String - Name of the project in which load balancer pool was created.
- region
Id Number - ID of the region in which load balancer pool was created.
- region
Name String - Name of the region in which load balancer pool was created.
Supporting Types
GetLbpoolHealthMonitor
- Delay double
- Expected
Codes string - Http
Method string - Id string
- Max
Retries double - Max
Retries doubleDown - Timeout double
- Type string
- Url
Path string
- Delay float64
- Expected
Codes string - Http
Method string - Id string
- Max
Retries float64 - Max
Retries float64Down - Timeout float64
- Type string
- Url
Path string
- delay Double
- expected
Codes String - http
Method String - id String
- max
Retries Double - max
Retries DoubleDown - timeout Double
- type String
- url
Path String
- delay number
- expected
Codes string - http
Method string - id string
- max
Retries number - max
Retries numberDown - timeout number
- type string
- url
Path string
- delay float
- expected_
codes str - http_
method str - id str
- max_
retries float - max_
retries_ floatdown - timeout float
- type str
- url_
path str
- delay Number
- expected
Codes String - http
Method String - id String
- max
Retries Number - max
Retries NumberDown - timeout Number
- type String
- url
Path String
GetLbpoolSessionPersistence
- string
- Persistence
Granularity string - Persistence
Timeout double - Type string
- string
- Persistence
Granularity string - Persistence
Timeout float64 - Type string
- String
- persistence
Granularity String - persistence
Timeout Double - type String
- string
- persistence
Granularity string - persistence
Timeout number - type string
- str
- persistence_
granularity str - persistence_
timeout float - type str
- String
- persistence
Granularity String - persistence
Timeout Number - type String
Package Details
- Repository
- gcore g-core/terraform-provider-gcore
- License
- Notes
- This Pulumi package is based on the
gcore
Terraform Provider.