1. Packages
  2. Cisco IOS XE Resource Provider
  3. API Docs
  4. BgpAddressFamilyIpv4
Cisco IOS XE v0.0.1 published on Friday, Sep 22, 2023 by lbrlabs

iosxe.BgpAddressFamilyIpv4

Explore with Pulumi AI

This resource can manage the BGP Address Family IPv4 configuration.

Example Usage

Coming soon!

Coming soon!

package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.iosxe.BgpAddressFamilyIpv4;
import com.pulumi.iosxe.BgpAddressFamilyIpv4Args;
import com.pulumi.iosxe.inputs.BgpAddressFamilyIpv4Ipv4UnicastNetworkArgs;
import com.pulumi.iosxe.inputs.BgpAddressFamilyIpv4Ipv4UnicastNetworksMaskArgs;
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) {
        var example = new BgpAddressFamilyIpv4("example", BgpAddressFamilyIpv4Args.builder()        
            .afName("unicast")
            .asn("65000")
            .ipv4UnicastNetworks(BgpAddressFamilyIpv4Ipv4UnicastNetworkArgs.builder()
                .backdoor(true)
                .network("13.0.0.0")
                .route_map("RM1")
                .build())
            .ipv4UnicastNetworksMasks(BgpAddressFamilyIpv4Ipv4UnicastNetworksMaskArgs.builder()
                .backdoor(true)
                .mask("255.255.0.0")
                .network("12.0.0.0")
                .route_map("RM1")
                .build())
            .ipv4UnicastRedistributeConnected(true)
            .ipv4UnicastRedistributeStatic(true)
            .build());

    }
}
Copy

Coming soon!

Coming soon!

resources:
  example:
    type: iosxe:BgpAddressFamilyIpv4
    properties:
      afName: unicast
      asn: '65000'
      ipv4UnicastNetworks:
        - backdoor: true
          network: 13.0.0.0
          route_map: RM1
      ipv4UnicastNetworksMasks:
        - backdoor: true
          mask: 255.255.0.0
          network: 12.0.0.0
          route_map: RM1
      ipv4UnicastRedistributeConnected: true
      ipv4UnicastRedistributeStatic: true
Copy

Create BgpAddressFamilyIpv4 Resource

Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

Constructor syntax

new BgpAddressFamilyIpv4(name: string, args: BgpAddressFamilyIpv4Args, opts?: CustomResourceOptions);
@overload
def BgpAddressFamilyIpv4(resource_name: str,
                         args: BgpAddressFamilyIpv4Args,
                         opts: Optional[ResourceOptions] = None)

@overload
def BgpAddressFamilyIpv4(resource_name: str,
                         opts: Optional[ResourceOptions] = None,
                         af_name: Optional[str] = None,
                         asn: Optional[str] = None,
                         delete_mode: Optional[str] = None,
                         device: Optional[str] = None,
                         ipv4_unicast_networks: Optional[Sequence[BgpAddressFamilyIpv4Ipv4UnicastNetworkArgs]] = None,
                         ipv4_unicast_networks_masks: Optional[Sequence[BgpAddressFamilyIpv4Ipv4UnicastNetworksMaskArgs]] = None,
                         ipv4_unicast_redistribute_connected: Optional[bool] = None,
                         ipv4_unicast_redistribute_static: Optional[bool] = None)
func NewBgpAddressFamilyIpv4(ctx *Context, name string, args BgpAddressFamilyIpv4Args, opts ...ResourceOption) (*BgpAddressFamilyIpv4, error)
public BgpAddressFamilyIpv4(string name, BgpAddressFamilyIpv4Args args, CustomResourceOptions? opts = null)
public BgpAddressFamilyIpv4(String name, BgpAddressFamilyIpv4Args args)
public BgpAddressFamilyIpv4(String name, BgpAddressFamilyIpv4Args args, CustomResourceOptions options)
type: iosxe:BgpAddressFamilyIpv4
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args This property is required. BgpAddressFamilyIpv4Args
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args This property is required. BgpAddressFamilyIpv4Args
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args This property is required. BgpAddressFamilyIpv4Args
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args This property is required. BgpAddressFamilyIpv4Args
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. BgpAddressFamilyIpv4Args
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

Constructor example

The following reference example uses placeholder values for all input properties.

var bgpAddressFamilyIpv4Resource = new Iosxe.BgpAddressFamilyIpv4("bgpAddressFamilyIpv4Resource", new()
{
    AfName = "string",
    Asn = "string",
    DeleteMode = "string",
    Device = "string",
    Ipv4UnicastNetworks = new[]
    {
        new Iosxe.Inputs.BgpAddressFamilyIpv4Ipv4UnicastNetworkArgs
        {
            Network = "string",
            Backdoor = false,
            RouteMap = "string",
        },
    },
    Ipv4UnicastNetworksMasks = new[]
    {
        new Iosxe.Inputs.BgpAddressFamilyIpv4Ipv4UnicastNetworksMaskArgs
        {
            Mask = "string",
            Network = "string",
            Backdoor = false,
            RouteMap = "string",
        },
    },
    Ipv4UnicastRedistributeConnected = false,
    Ipv4UnicastRedistributeStatic = false,
});
Copy
example, err := iosxe.NewBgpAddressFamilyIpv4(ctx, "bgpAddressFamilyIpv4Resource", &iosxe.BgpAddressFamilyIpv4Args{
	AfName:     pulumi.String("string"),
	Asn:        pulumi.String("string"),
	DeleteMode: pulumi.String("string"),
	Device:     pulumi.String("string"),
	Ipv4UnicastNetworks: iosxe.BgpAddressFamilyIpv4Ipv4UnicastNetworkArray{
		&iosxe.BgpAddressFamilyIpv4Ipv4UnicastNetworkArgs{
			Network:  pulumi.String("string"),
			Backdoor: pulumi.Bool(false),
			RouteMap: pulumi.String("string"),
		},
	},
	Ipv4UnicastNetworksMasks: iosxe.BgpAddressFamilyIpv4Ipv4UnicastNetworksMaskArray{
		&iosxe.BgpAddressFamilyIpv4Ipv4UnicastNetworksMaskArgs{
			Mask:     pulumi.String("string"),
			Network:  pulumi.String("string"),
			Backdoor: pulumi.Bool(false),
			RouteMap: pulumi.String("string"),
		},
	},
	Ipv4UnicastRedistributeConnected: pulumi.Bool(false),
	Ipv4UnicastRedistributeStatic:    pulumi.Bool(false),
})
Copy
var bgpAddressFamilyIpv4Resource = new BgpAddressFamilyIpv4("bgpAddressFamilyIpv4Resource", BgpAddressFamilyIpv4Args.builder()
    .afName("string")
    .asn("string")
    .deleteMode("string")
    .device("string")
    .ipv4UnicastNetworks(BgpAddressFamilyIpv4Ipv4UnicastNetworkArgs.builder()
        .network("string")
        .backdoor(false)
        .routeMap("string")
        .build())
    .ipv4UnicastNetworksMasks(BgpAddressFamilyIpv4Ipv4UnicastNetworksMaskArgs.builder()
        .mask("string")
        .network("string")
        .backdoor(false)
        .routeMap("string")
        .build())
    .ipv4UnicastRedistributeConnected(false)
    .ipv4UnicastRedistributeStatic(false)
    .build());
Copy
bgp_address_family_ipv4_resource = iosxe.BgpAddressFamilyIpv4("bgpAddressFamilyIpv4Resource",
    af_name="string",
    asn="string",
    delete_mode="string",
    device="string",
    ipv4_unicast_networks=[{
        "network": "string",
        "backdoor": False,
        "route_map": "string",
    }],
    ipv4_unicast_networks_masks=[{
        "mask": "string",
        "network": "string",
        "backdoor": False,
        "route_map": "string",
    }],
    ipv4_unicast_redistribute_connected=False,
    ipv4_unicast_redistribute_static=False)
Copy
const bgpAddressFamilyIpv4Resource = new iosxe.BgpAddressFamilyIpv4("bgpAddressFamilyIpv4Resource", {
    afName: "string",
    asn: "string",
    deleteMode: "string",
    device: "string",
    ipv4UnicastNetworks: [{
        network: "string",
        backdoor: false,
        routeMap: "string",
    }],
    ipv4UnicastNetworksMasks: [{
        mask: "string",
        network: "string",
        backdoor: false,
        routeMap: "string",
    }],
    ipv4UnicastRedistributeConnected: false,
    ipv4UnicastRedistributeStatic: false,
});
Copy
type: iosxe:BgpAddressFamilyIpv4
properties:
    afName: string
    asn: string
    deleteMode: string
    device: string
    ipv4UnicastNetworks:
        - backdoor: false
          network: string
          routeMap: string
    ipv4UnicastNetworksMasks:
        - backdoor: false
          mask: string
          network: string
          routeMap: string
    ipv4UnicastRedistributeConnected: false
    ipv4UnicastRedistributeStatic: false
Copy

BgpAddressFamilyIpv4 Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

The BgpAddressFamilyIpv4 resource accepts the following input properties:

AfName This property is required. string
  • Choices: flowspec, labeled-unicast, mdt, multicast, mvpn, sr-policy, tunnel, unicast
Asn This property is required. string
DeleteMode string
Configure behavior when deleting/destroying the resource. Either delete the entire object (YANG container) being managed, or only delete the individual resource attributes configured explicitly and leave everything else as-is. Default value is all. - Choices: all, attributes
Device string
A device name from the provider configuration.
Ipv4UnicastNetworks List<Lbrlabs.PulumiPackage.Iosxe.Inputs.BgpAddressFamilyIpv4Ipv4UnicastNetwork>
Specify a network to announce via BGP
Ipv4UnicastNetworksMasks List<Lbrlabs.PulumiPackage.Iosxe.Inputs.BgpAddressFamilyIpv4Ipv4UnicastNetworksMask>
Specify a network to announce via BGP
Ipv4UnicastRedistributeConnected bool
Connected
Ipv4UnicastRedistributeStatic bool
Static routes
AfName This property is required. string
  • Choices: flowspec, labeled-unicast, mdt, multicast, mvpn, sr-policy, tunnel, unicast
Asn This property is required. string
DeleteMode string
Configure behavior when deleting/destroying the resource. Either delete the entire object (YANG container) being managed, or only delete the individual resource attributes configured explicitly and leave everything else as-is. Default value is all. - Choices: all, attributes
Device string
A device name from the provider configuration.
Ipv4UnicastNetworks []BgpAddressFamilyIpv4Ipv4UnicastNetworkArgs
Specify a network to announce via BGP
Ipv4UnicastNetworksMasks []BgpAddressFamilyIpv4Ipv4UnicastNetworksMaskArgs
Specify a network to announce via BGP
Ipv4UnicastRedistributeConnected bool
Connected
Ipv4UnicastRedistributeStatic bool
Static routes
afName This property is required. String
  • Choices: flowspec, labeled-unicast, mdt, multicast, mvpn, sr-policy, tunnel, unicast
asn This property is required. String
deleteMode String
Configure behavior when deleting/destroying the resource. Either delete the entire object (YANG container) being managed, or only delete the individual resource attributes configured explicitly and leave everything else as-is. Default value is all. - Choices: all, attributes
device String
A device name from the provider configuration.
ipv4UnicastNetworks List<BgpAddressFamilyIpv4Ipv4UnicastNetwork>
Specify a network to announce via BGP
ipv4UnicastNetworksMasks List<BgpAddressFamilyIpv4Ipv4UnicastNetworksMask>
Specify a network to announce via BGP
ipv4UnicastRedistributeConnected Boolean
Connected
ipv4UnicastRedistributeStatic Boolean
Static routes
afName This property is required. string
  • Choices: flowspec, labeled-unicast, mdt, multicast, mvpn, sr-policy, tunnel, unicast
asn This property is required. string
deleteMode string
Configure behavior when deleting/destroying the resource. Either delete the entire object (YANG container) being managed, or only delete the individual resource attributes configured explicitly and leave everything else as-is. Default value is all. - Choices: all, attributes
device string
A device name from the provider configuration.
ipv4UnicastNetworks BgpAddressFamilyIpv4Ipv4UnicastNetwork[]
Specify a network to announce via BGP
ipv4UnicastNetworksMasks BgpAddressFamilyIpv4Ipv4UnicastNetworksMask[]
Specify a network to announce via BGP
ipv4UnicastRedistributeConnected boolean
Connected
ipv4UnicastRedistributeStatic boolean
Static routes
af_name This property is required. str
  • Choices: flowspec, labeled-unicast, mdt, multicast, mvpn, sr-policy, tunnel, unicast
asn This property is required. str
delete_mode str
Configure behavior when deleting/destroying the resource. Either delete the entire object (YANG container) being managed, or only delete the individual resource attributes configured explicitly and leave everything else as-is. Default value is all. - Choices: all, attributes
device str
A device name from the provider configuration.
ipv4_unicast_networks Sequence[BgpAddressFamilyIpv4Ipv4UnicastNetworkArgs]
Specify a network to announce via BGP
ipv4_unicast_networks_masks Sequence[BgpAddressFamilyIpv4Ipv4UnicastNetworksMaskArgs]
Specify a network to announce via BGP
ipv4_unicast_redistribute_connected bool
Connected
ipv4_unicast_redistribute_static bool
Static routes
afName This property is required. String
  • Choices: flowspec, labeled-unicast, mdt, multicast, mvpn, sr-policy, tunnel, unicast
asn This property is required. String
deleteMode String
Configure behavior when deleting/destroying the resource. Either delete the entire object (YANG container) being managed, or only delete the individual resource attributes configured explicitly and leave everything else as-is. Default value is all. - Choices: all, attributes
device String
A device name from the provider configuration.
ipv4UnicastNetworks List<Property Map>
Specify a network to announce via BGP
ipv4UnicastNetworksMasks List<Property Map>
Specify a network to announce via BGP
ipv4UnicastRedistributeConnected Boolean
Connected
ipv4UnicastRedistributeStatic Boolean
Static routes

Outputs

All input properties are implicitly available as output properties. Additionally, the BgpAddressFamilyIpv4 resource produces the following output properties:

Id string
The provider-assigned unique ID for this managed resource.
Id string
The provider-assigned unique ID for this managed resource.
id String
The provider-assigned unique ID for this managed resource.
id string
The provider-assigned unique ID for this managed resource.
id str
The provider-assigned unique ID for this managed resource.
id String
The provider-assigned unique ID for this managed resource.

Look up Existing BgpAddressFamilyIpv4 Resource

Get an existing BgpAddressFamilyIpv4 resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

public static get(name: string, id: Input<ID>, state?: BgpAddressFamilyIpv4State, opts?: CustomResourceOptions): BgpAddressFamilyIpv4
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        af_name: Optional[str] = None,
        asn: Optional[str] = None,
        delete_mode: Optional[str] = None,
        device: Optional[str] = None,
        ipv4_unicast_networks: Optional[Sequence[BgpAddressFamilyIpv4Ipv4UnicastNetworkArgs]] = None,
        ipv4_unicast_networks_masks: Optional[Sequence[BgpAddressFamilyIpv4Ipv4UnicastNetworksMaskArgs]] = None,
        ipv4_unicast_redistribute_connected: Optional[bool] = None,
        ipv4_unicast_redistribute_static: Optional[bool] = None) -> BgpAddressFamilyIpv4
func GetBgpAddressFamilyIpv4(ctx *Context, name string, id IDInput, state *BgpAddressFamilyIpv4State, opts ...ResourceOption) (*BgpAddressFamilyIpv4, error)
public static BgpAddressFamilyIpv4 Get(string name, Input<string> id, BgpAddressFamilyIpv4State? state, CustomResourceOptions? opts = null)
public static BgpAddressFamilyIpv4 get(String name, Output<String> id, BgpAddressFamilyIpv4State state, CustomResourceOptions options)
resources:  _:    type: iosxe:BgpAddressFamilyIpv4    get:      id: ${id}
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
resource_name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
The following state arguments are supported:
AfName string
  • Choices: flowspec, labeled-unicast, mdt, multicast, mvpn, sr-policy, tunnel, unicast
Asn string
DeleteMode string
Configure behavior when deleting/destroying the resource. Either delete the entire object (YANG container) being managed, or only delete the individual resource attributes configured explicitly and leave everything else as-is. Default value is all. - Choices: all, attributes
Device string
A device name from the provider configuration.
Ipv4UnicastNetworks List<Lbrlabs.PulumiPackage.Iosxe.Inputs.BgpAddressFamilyIpv4Ipv4UnicastNetwork>
Specify a network to announce via BGP
Ipv4UnicastNetworksMasks List<Lbrlabs.PulumiPackage.Iosxe.Inputs.BgpAddressFamilyIpv4Ipv4UnicastNetworksMask>
Specify a network to announce via BGP
Ipv4UnicastRedistributeConnected bool
Connected
Ipv4UnicastRedistributeStatic bool
Static routes
AfName string
  • Choices: flowspec, labeled-unicast, mdt, multicast, mvpn, sr-policy, tunnel, unicast
Asn string
DeleteMode string
Configure behavior when deleting/destroying the resource. Either delete the entire object (YANG container) being managed, or only delete the individual resource attributes configured explicitly and leave everything else as-is. Default value is all. - Choices: all, attributes
Device string
A device name from the provider configuration.
Ipv4UnicastNetworks []BgpAddressFamilyIpv4Ipv4UnicastNetworkArgs
Specify a network to announce via BGP
Ipv4UnicastNetworksMasks []BgpAddressFamilyIpv4Ipv4UnicastNetworksMaskArgs
Specify a network to announce via BGP
Ipv4UnicastRedistributeConnected bool
Connected
Ipv4UnicastRedistributeStatic bool
Static routes
afName String
  • Choices: flowspec, labeled-unicast, mdt, multicast, mvpn, sr-policy, tunnel, unicast
asn String
deleteMode String
Configure behavior when deleting/destroying the resource. Either delete the entire object (YANG container) being managed, or only delete the individual resource attributes configured explicitly and leave everything else as-is. Default value is all. - Choices: all, attributes
device String
A device name from the provider configuration.
ipv4UnicastNetworks List<BgpAddressFamilyIpv4Ipv4UnicastNetwork>
Specify a network to announce via BGP
ipv4UnicastNetworksMasks List<BgpAddressFamilyIpv4Ipv4UnicastNetworksMask>
Specify a network to announce via BGP
ipv4UnicastRedistributeConnected Boolean
Connected
ipv4UnicastRedistributeStatic Boolean
Static routes
afName string
  • Choices: flowspec, labeled-unicast, mdt, multicast, mvpn, sr-policy, tunnel, unicast
asn string
deleteMode string
Configure behavior when deleting/destroying the resource. Either delete the entire object (YANG container) being managed, or only delete the individual resource attributes configured explicitly and leave everything else as-is. Default value is all. - Choices: all, attributes
device string
A device name from the provider configuration.
ipv4UnicastNetworks BgpAddressFamilyIpv4Ipv4UnicastNetwork[]
Specify a network to announce via BGP
ipv4UnicastNetworksMasks BgpAddressFamilyIpv4Ipv4UnicastNetworksMask[]
Specify a network to announce via BGP
ipv4UnicastRedistributeConnected boolean
Connected
ipv4UnicastRedistributeStatic boolean
Static routes
af_name str
  • Choices: flowspec, labeled-unicast, mdt, multicast, mvpn, sr-policy, tunnel, unicast
asn str
delete_mode str
Configure behavior when deleting/destroying the resource. Either delete the entire object (YANG container) being managed, or only delete the individual resource attributes configured explicitly and leave everything else as-is. Default value is all. - Choices: all, attributes
device str
A device name from the provider configuration.
ipv4_unicast_networks Sequence[BgpAddressFamilyIpv4Ipv4UnicastNetworkArgs]
Specify a network to announce via BGP
ipv4_unicast_networks_masks Sequence[BgpAddressFamilyIpv4Ipv4UnicastNetworksMaskArgs]
Specify a network to announce via BGP
ipv4_unicast_redistribute_connected bool
Connected
ipv4_unicast_redistribute_static bool
Static routes
afName String
  • Choices: flowspec, labeled-unicast, mdt, multicast, mvpn, sr-policy, tunnel, unicast
asn String
deleteMode String
Configure behavior when deleting/destroying the resource. Either delete the entire object (YANG container) being managed, or only delete the individual resource attributes configured explicitly and leave everything else as-is. Default value is all. - Choices: all, attributes
device String
A device name from the provider configuration.
ipv4UnicastNetworks List<Property Map>
Specify a network to announce via BGP
ipv4UnicastNetworksMasks List<Property Map>
Specify a network to announce via BGP
ipv4UnicastRedistributeConnected Boolean
Connected
ipv4UnicastRedistributeStatic Boolean
Static routes

Supporting Types

BgpAddressFamilyIpv4Ipv4UnicastNetwork
, BgpAddressFamilyIpv4Ipv4UnicastNetworkArgs

Network This property is required. string
Backdoor bool
RouteMap string
Network This property is required. string
Backdoor bool
RouteMap string
network This property is required. String
backdoor Boolean
routeMap String
network This property is required. string
backdoor boolean
routeMap string
network This property is required. str
backdoor bool
route_map str
network This property is required. String
backdoor Boolean
routeMap String

BgpAddressFamilyIpv4Ipv4UnicastNetworksMask
, BgpAddressFamilyIpv4Ipv4UnicastNetworksMaskArgs

Mask This property is required. string
Network This property is required. string
Backdoor bool
RouteMap string
Mask This property is required. string
Network This property is required. string
Backdoor bool
RouteMap string
mask This property is required. String
network This property is required. String
backdoor Boolean
routeMap String
mask This property is required. string
network This property is required. string
backdoor boolean
routeMap string
mask This property is required. str
network This property is required. str
backdoor bool
route_map str
mask This property is required. String
network This property is required. String
backdoor Boolean
routeMap String

Import

 $ pulumi import iosxe:index/bgpAddressFamilyIpv4:BgpAddressFamilyIpv4 example "Cisco-IOS-XE-native:native/router/Cisco-IOS-XE-bgp:bgp=65000/address-family/no-vrf/ipv4=unicast"
Copy

To learn more about importing existing cloud resources, see Importing resources.

Package Details

Repository
iosxe lbrlabs/pulumi-iosxe
License
Apache-2.0
Notes
This Pulumi package is based on the iosxe Terraform Provider.