Cisco NX-OS v0.0.2 published on Friday, Sep 29, 2023 by lbrlabs
nxos.getBgpPeer
Explore with Pulumi AI
This data source can read the BGP peer configuration.
- API Documentation: bgpPeer
Example Usage
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Nxos = Pulumi.Nxos;
return await Deployment.RunAsync(() =>
{
var example = Nxos.GetBgpPeer.Invoke(new()
{
Address = "192.168.0.1",
Asn = "65001",
Vrf = "default",
});
});
package main
import (
"github.com/lbrlabs/pulumi-nxos/sdk/go/nxos"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := nxos.LookupBgpPeer(ctx, &nxos.LookupBgpPeerArgs{
Address: "192.168.0.1",
Asn: "65001",
Vrf: "default",
}, nil)
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.nxos.NxosFunctions;
import com.pulumi.nxos.inputs.GetBgpPeerArgs;
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 example = NxosFunctions.getBgpPeer(GetBgpPeerArgs.builder()
.address("192.168.0.1")
.asn("65001")
.vrf("default")
.build());
}
}
import pulumi
import pulumi_nxos as nxos
example = nxos.get_bgp_peer(address="192.168.0.1",
asn="65001",
vrf="default")
import * as pulumi from "@pulumi/pulumi";
import * as nxos from "@pulumi/nxos";
const example = nxos.getBgpPeer({
address: "192.168.0.1",
asn: "65001",
vrf: "default",
});
variables:
example:
fn::invoke:
Function: nxos:getBgpPeer
Arguments:
address: 192.168.0.1
asn: '65001'
vrf: default
Using getBgpPeer
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 getBgpPeer(args: GetBgpPeerArgs, opts?: InvokeOptions): Promise<GetBgpPeerResult>
function getBgpPeerOutput(args: GetBgpPeerOutputArgs, opts?: InvokeOptions): Output<GetBgpPeerResult>
def get_bgp_peer(address: Optional[str] = None,
asn: Optional[str] = None,
device: Optional[str] = None,
vrf: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetBgpPeerResult
def get_bgp_peer_output(address: Optional[pulumi.Input[str]] = None,
asn: Optional[pulumi.Input[str]] = None,
device: Optional[pulumi.Input[str]] = None,
vrf: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetBgpPeerResult]
func LookupBgpPeer(ctx *Context, args *LookupBgpPeerArgs, opts ...InvokeOption) (*LookupBgpPeerResult, error)
func LookupBgpPeerOutput(ctx *Context, args *LookupBgpPeerOutputArgs, opts ...InvokeOption) LookupBgpPeerResultOutput
> Note: This function is named LookupBgpPeer
in the Go SDK.
public static class GetBgpPeer
{
public static Task<GetBgpPeerResult> InvokeAsync(GetBgpPeerArgs args, InvokeOptions? opts = null)
public static Output<GetBgpPeerResult> Invoke(GetBgpPeerInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetBgpPeerResult> getBgpPeer(GetBgpPeerArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: nxos:index/getBgpPeer:getBgpPeer
arguments:
# arguments dictionary
The following arguments are supported:
getBgpPeer Result
The following output properties are available:
- Address string
- Peer address.
- Asn string
- Autonomous system number.
- Description string
- Peer description.
- Hold
Time int - BGP Hold Timer in seconds. The value must be greater than the keepalive timer
- Id string
- The distinguished name of the object.
- Keepalive int
- BGP Keepalive Timer in seconds
- Peer
Template string - Peer template name.
- Peer
Type string - Neighbor Fabric Type.
- Remote
Asn string - Peer autonomous system number.
- Source
Interface string - Source Interface. Must match first field in the output of
show intf brief
. - Vrf string
- VRF name.
- Device string
- A device name from the provider configuration.
- Address string
- Peer address.
- Asn string
- Autonomous system number.
- Description string
- Peer description.
- Hold
Time int - BGP Hold Timer in seconds. The value must be greater than the keepalive timer
- Id string
- The distinguished name of the object.
- Keepalive int
- BGP Keepalive Timer in seconds
- Peer
Template string - Peer template name.
- Peer
Type string - Neighbor Fabric Type.
- Remote
Asn string - Peer autonomous system number.
- Source
Interface string - Source Interface. Must match first field in the output of
show intf brief
. - Vrf string
- VRF name.
- Device string
- A device name from the provider configuration.
- address String
- Peer address.
- asn String
- Autonomous system number.
- description String
- Peer description.
- hold
Time Integer - BGP Hold Timer in seconds. The value must be greater than the keepalive timer
- id String
- The distinguished name of the object.
- keepalive Integer
- BGP Keepalive Timer in seconds
- peer
Template String - Peer template name.
- peer
Type String - Neighbor Fabric Type.
- remote
Asn String - Peer autonomous system number.
- source
Interface String - Source Interface. Must match first field in the output of
show intf brief
. - vrf String
- VRF name.
- device String
- A device name from the provider configuration.
- address string
- Peer address.
- asn string
- Autonomous system number.
- description string
- Peer description.
- hold
Time number - BGP Hold Timer in seconds. The value must be greater than the keepalive timer
- id string
- The distinguished name of the object.
- keepalive number
- BGP Keepalive Timer in seconds
- peer
Template string - Peer template name.
- peer
Type string - Neighbor Fabric Type.
- remote
Asn string - Peer autonomous system number.
- source
Interface string - Source Interface. Must match first field in the output of
show intf brief
. - vrf string
- VRF name.
- device string
- A device name from the provider configuration.
- address str
- Peer address.
- asn str
- Autonomous system number.
- description str
- Peer description.
- hold_
time int - BGP Hold Timer in seconds. The value must be greater than the keepalive timer
- id str
- The distinguished name of the object.
- keepalive int
- BGP Keepalive Timer in seconds
- peer_
template str - Peer template name.
- peer_
type str - Neighbor Fabric Type.
- remote_
asn str - Peer autonomous system number.
- source_
interface str - Source Interface. Must match first field in the output of
show intf brief
. - vrf str
- VRF name.
- device str
- A device name from the provider configuration.
- address String
- Peer address.
- asn String
- Autonomous system number.
- description String
- Peer description.
- hold
Time Number - BGP Hold Timer in seconds. The value must be greater than the keepalive timer
- id String
- The distinguished name of the object.
- keepalive Number
- BGP Keepalive Timer in seconds
- peer
Template String - Peer template name.
- peer
Type String - Neighbor Fabric Type.
- remote
Asn String - Peer autonomous system number.
- source
Interface String - Source Interface. Must match first field in the output of
show intf brief
. - vrf String
- VRF name.
- device String
- A device name from the provider configuration.
Package Details
- Repository
- nxos lbrlabs/pulumi-nxos
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
nxos
Terraform Provider.