Consul v3.12.2 published on Wednesday, Oct 16, 2024 by Pulumi
consul.getPeering
Explore with Pulumi AI
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as consul from "@pulumi/consul";
const basic = consul.getPeering({
peerName: "peered-cluster",
});
import pulumi
import pulumi_consul as consul
basic = consul.get_peering(peer_name="peered-cluster")
package main
import (
"github.com/pulumi/pulumi-consul/sdk/v3/go/consul"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := consul.LookupPeering(ctx, &consul.LookupPeeringArgs{
PeerName: "peered-cluster",
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Consul = Pulumi.Consul;
return await Deployment.RunAsync(() =>
{
var basic = Consul.GetPeering.Invoke(new()
{
PeerName = "peered-cluster",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.consul.ConsulFunctions;
import com.pulumi.consul.inputs.GetPeeringArgs;
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 basic = ConsulFunctions.getPeering(GetPeeringArgs.builder()
.peerName("peered-cluster")
.build());
}
}
variables:
basic:
fn::invoke:
Function: consul:getPeering
Arguments:
peerName: peered-cluster
Using getPeering
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 getPeering(args: GetPeeringArgs, opts?: InvokeOptions): Promise<GetPeeringResult>
function getPeeringOutput(args: GetPeeringOutputArgs, opts?: InvokeOptions): Output<GetPeeringResult>
def get_peering(partition: Optional[str] = None,
peer_name: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetPeeringResult
def get_peering_output(partition: Optional[pulumi.Input[str]] = None,
peer_name: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetPeeringResult]
func LookupPeering(ctx *Context, args *LookupPeeringArgs, opts ...InvokeOption) (*LookupPeeringResult, error)
func LookupPeeringOutput(ctx *Context, args *LookupPeeringOutputArgs, opts ...InvokeOption) LookupPeeringResultOutput
> Note: This function is named LookupPeering
in the Go SDK.
public static class GetPeering
{
public static Task<GetPeeringResult> InvokeAsync(GetPeeringArgs args, InvokeOptions? opts = null)
public static Output<GetPeeringResult> Invoke(GetPeeringInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetPeeringResult> getPeering(GetPeeringArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: consul:index/getPeering:getPeering
arguments:
# arguments dictionary
The following arguments are supported:
getPeering Result
The following output properties are available:
- Deleted
At string - Id string
- The provider-assigned unique ID for this managed resource.
- Meta Dictionary<string, string>
- Peer
Ca List<string>Pems - Peer
Id string - Peer
Name string - Peer
Server List<string>Addresses - Peer
Server stringName - State string
- Partition string
- Deleted
At string - Id string
- The provider-assigned unique ID for this managed resource.
- Meta map[string]string
- Peer
Ca []stringPems - Peer
Id string - Peer
Name string - Peer
Server []stringAddresses - Peer
Server stringName - State string
- Partition string
- deleted
At String - id String
- The provider-assigned unique ID for this managed resource.
- meta Map<String,String>
- peer
Ca List<String>Pems - peer
Id String - peer
Name String - peer
Server List<String>Addresses - peer
Server StringName - state String
- partition String
- deleted
At string - id string
- The provider-assigned unique ID for this managed resource.
- meta {[key: string]: string}
- peer
Ca string[]Pems - peer
Id string - peer
Name string - peer
Server string[]Addresses - peer
Server stringName - state string
- partition string
- deleted_
at str - id str
- The provider-assigned unique ID for this managed resource.
- meta Mapping[str, str]
- peer_
ca_ Sequence[str]pems - peer_
id str - peer_
name str - peer_
server_ Sequence[str]addresses - peer_
server_ strname - state str
- partition str
- deleted
At String - id String
- The provider-assigned unique ID for this managed resource.
- meta Map<String>
- peer
Ca List<String>Pems - peer
Id String - peer
Name String - peer
Server List<String>Addresses - peer
Server StringName - state String
- partition String
Package Details
- Repository
- HashiCorp Consul pulumi/pulumi-consul
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
consul
Terraform Provider.