Skip to content
This repository has been archived by the owner on Jan 12, 2024. It is now read-only.

netascode/terraform-aci-vrf

Tests

This module is no longer maintained as it has been integrated into the nac-aci module.

Terraform ACI VRF Module

Manages ACI VRF

Location in GUI: Tenants » XXX » Networking » VRFs

Examples

module "aci_vrf" {
  source  = "netascode/vrf/aci"
  version = ">= 0.2.4"

  tenant                                 = "ABC"
  name                                   = "VRF1"
  alias                                  = "VRF1-ALIAS"
  description                            = "My Description"
  enforcement_direction                  = "egress"
  enforcement_preference                 = "unenforced"
  data_plane_learning                    = false
  preferred_group                        = true
  transit_route_tag_policy               = "TRP1"
  bgp_timer_policy                       = "BGP1"
  bgp_ipv4_address_family_context_policy = "BGP_AF_IPV4"
  bgp_ipv6_address_family_context_policy = "BGP_AF_IPV6"
  bgp_ipv4_import_route_target           = "route-target:as2-nn2:10:10"
  bgp_ipv4_export_route_target           = "route-target:as2-nn2:10:10"
  bgp_ipv6_import_route_target           = "route-target:as2-nn2:10:10"
  bgp_ipv6_export_route_target           = "route-target:as2-nn2:10:10"
  dns_labels                             = ["DNS1"]
  contract_consumers                     = ["CON1"]
  contract_providers                     = ["CON1"]
  contract_imported_consumers            = ["I_CON1"]
  pim_enabled                            = true
  pim_mtu                                = 9200
  pim_fast_convergence                   = true
  pim_strict_rfc                         = true
  pim_max_multicast_entries              = 1000
  pim_reserved_multicast_entries         = "undefined"
  pim_static_rps = [
    {
      ip                  = "1.1.1.1"
      multicast_route_map = "TEST_RM"
    },
    {
      ip = "1.1.1.2"
    },
  ]
  pim_fabric_rps = [
    {
      ip                  = "2.2.2.1"
      multicast_route_map = "TEST_RM"
    },
    {
      ip = "2.2.2.2"
    }
  ]
  pim_bsr_listen_updates                   = true
  pim_bsr_forward_updates                  = true
  pim_bsr_filter_multicast_route_map       = "MCAST_RM1"
  pim_auto_rp_listen_updates               = true
  pim_auto_rp_forward_updates              = true
  pim_auto_rp_filter_multicast_route_map   = "MCAST_RM2"
  pim_asm_shared_range_multicast_route_map = "MCAST_RM3"
  pim_asm_sg_expiry                        = 1800
  pim_asm_sg_expiry_multicast_route_map    = "MCAST_RM4"
  pim_asm_traffic_registry_max_rate        = 10
  pim_asm_traffic_registry_source_ip       = "1.1.1.1"
  pim_ssm_group_range_multicast_route_map  = "MCAST_RM5"
  pim_inter_vrf_policies = [
    {
      tenant              = "TEN2"
      vrf                 = "VRF1"
      multicast_route_map = "MCAST_RM6"
    }
  ]
  pim_igmp_ssm_translate_policies = [
    {
      group_prefix   = "228.0.0.0/8"
      source_address = "3.3.3.3"
    },
    {
      group_prefix   = "229.0.0.0/8"
      source_address = "4.4.4.4"
    }
  ]
  leaked_internal_prefixes = [{
    prefix = "1.1.1.0/24"
    public = true
    destinations = [{
      description = "Leak to VRF2"
      tenant      = "ABC"
      vrf         = "VRF2"
      public      = false
    }]
  }]
  leaked_external_prefixes = [{
    prefix             = "2.2.0.0/16"
    from_prefix_length = 24
    to_prefix_length   = 32
    destinations = [{
      description = "Leak to VRF2"
      tenant      = "ABC"
      vrf         = "VRF2"
    }]
  }]
}

Requirements

Name Version
terraform >= 1.3.0
aci >= 2.0.0

Providers

Name Version
aci >= 2.0.0

Inputs

Name Description Type Default Required
tenant Tenant name. string n/a yes
name VRF name. string n/a yes
alias VRF alias. string "" no
description VRF description. string "" no
enforcement_direction VRF enforcement direction. Choices: ingress, egress. string "ingress" no
enforcement_preference VRF enforcement preference. Choices: enforced, unenforced. string "enforced" no
data_plane_learning VRF data plane learning. bool true no
preferred_group VRF preferred group member. bool false no
transit_route_tag_policy VRF transit route tag policy name. string "" no
bgp_timer_policy VRF BGP timer policy name. string "" no
bgp_ipv4_address_family_context_policy VRF BGP IPv4 Address Family Context policy name. string "" no
bgp_ipv6_address_family_context_policy VRF BGP IPv6 Address Family Context policy name. string "" no
bgp_ipv4_import_route_target VRF BGP IPv4 import route target. string "" no
bgp_ipv4_export_route_target VRF BGP IPv4 export route target. string "" no
bgp_ipv6_import_route_target VRF BGP IPv6 import route target. string "" no
bgp_ipv6_export_route_target VRF BGP IPv6 export route target. string "" no
dns_labels List of VRF DNS labels. list(string) [] no
contract_consumers List of contract consumers. list(string) [] no
contract_providers List of contract providers. list(string) [] no
contract_imported_consumers List of imported contract consumers. list(string) [] no
pim_enabled Enable PIM. Default value: false. bool false no
pim_mtu VRF PIM MTU. Allowed values 1-9300. Default value 1500 number 1500 no
pim_fast_convergence VRF PIM fast convergence. Default value: false. bool false no
pim_strict_rfc VRF PIM Strict RFC compliant. Default value: false. bool false no
pim_max_multicast_entries VRF PIM maximum number of multicast entries. Allowed valued between 1-4294967295 or unlimited. Default value unlimited. string "unlimited" no
pim_reserved_multicast_entries VRF PIM maximum number of multicast entries. Allowed valued between 0-4294967295. Default value undefined string "undefined" no
pim_resource_policy_multicast_route_map VRF PIM resource policy multicast route map. string "" no
pim_static_rps VRF PIM static RPs.
list(object({
ip = string
multicast_route_map = optional(string, "")
}))
[] no
pim_fabric_rps VRF PIM fabric RPs.
list(object({
ip = string
multicast_route_map = optional(string, "")
}))
[] no
pim_bsr_forward_updates VRF PIM BSR forward updates flag. Default value: false. bool false no
pim_bsr_listen_updates VRF PIM BSR listen updates flag. Default value: false. bool false no
pim_bsr_filter_multicast_route_map VRF PIM BSR multicast route map. string "" no
pim_auto_rp_forward_updates VRF PIM auto RP forward updates flag. Default value: false. bool false no
pim_auto_rp_listen_updates VRF PIM auto RP listen updates flag. Default value: false. bool false no
pim_auto_rp_filter_multicast_route_map VRF PIM auto RP multicast route map. string "" no
pim_asm_shared_range_multicast_route_map VRF PIM ASM shared range multicast route map. string "" no
pim_asm_sg_expiry VRF PIM ASM SG expiry timeout. Allowed values 180-604801 or default-timeout. Default value default-timeout string "default-timeout" no
pim_asm_sg_expiry_multicast_route_map VRF PIM SG expiry multicast route map. string "" no
pim_asm_traffic_registry_max_rate VRF PIM ASM traffic registry max rate. Allowed values bewtween 1-65535. Default value 65535 number 65535 no
pim_asm_traffic_registry_source_ip VRF PIM ASM traffic registry source IP. string "" no
pim_ssm_group_range_multicast_route_map VRF PIM SSM group range multicast route map. string "" no
pim_inter_vrf_policies VRF PIM inter-VRF policies.
list(object({
tenant = string
vrf = string
multicast_route_map = optional(string, "")
}))
[] no
pim_igmp_ssm_translate_policies VRF IGMP SSM tranlate policies.
list(object({
group_prefix = string
source_address = string
}))
[] no
leaked_internal_prefixes List of leaked internal prefixes. Default value public: false.
list(object({
prefix = string
public = optional(bool, false)
destinations = optional(list(object({
description = optional(string, "")
tenant = string
vrf = string
public = optional(bool)
})), [])
}))
[] no
leaked_external_prefixes List of leaked external prefixes.
list(object({
prefix = string
from_prefix_length = optional(number)
to_prefix_length = optional(number)
destinations = optional(list(object({
description = optional(string, "")
tenant = string
vrf = string
})), [])
}))
[] no

Outputs

Name Description
dn Distinguished name of fvCtx object.
name VRF name.

Resources

Name Type
aci_rest_managed.bgpRtTargetP_ipv4 resource
aci_rest_managed.bgpRtTargetP_ipv6 resource
aci_rest_managed.bgpRtTarget_ipv4_export resource
aci_rest_managed.bgpRtTarget_ipv4_import resource
aci_rest_managed.bgpRtTarget_ipv6_export resource
aci_rest_managed.bgpRtTarget_ipv6_import resource
aci_rest_managed.dnsLbl resource
aci_rest_managed.fvCtx resource
aci_rest_managed.fvRsBgpCtxPol resource
aci_rest_managed.fvRsCtxToBgpCtxAfPol_ipv4 resource
aci_rest_managed.fvRsCtxToBgpCtxAfPol_ipv6 resource
aci_rest_managed.fvRsCtxToExtRouteTagPol resource
aci_rest_managed.igmpCtxP resource
aci_rest_managed.igmpSSMXlateP resource
aci_rest_managed.leakExternalPrefix resource
aci_rest_managed.leakInternalSubnet resource
aci_rest_managed.leakRoutes resource
aci_rest_managed.leakTo_external resource
aci_rest_managed.leakTo_internal resource
aci_rest_managed.pimASMPatPol resource
aci_rest_managed.pimAutoRPPol resource
aci_rest_managed.pimBSRFilterPol resource
aci_rest_managed.pimBSRPPol resource
aci_rest_managed.pimCtxP resource
aci_rest_managed.pimFabricRPPol resource
aci_rest_managed.pimInterVRFEntryPol resource
aci_rest_managed.pimInterVRFPol resource
aci_rest_managed.pimMAFilterPol resource
aci_rest_managed.pimRPGrpRangePol_fabric_rp resource
aci_rest_managed.pimRPGrpRangePol_static_rp resource
aci_rest_managed.pimRegTrPol resource
aci_rest_managed.pimResPol resource
aci_rest_managed.pimSGRangeExpPol resource
aci_rest_managed.pimSSMPatPol resource
aci_rest_managed.pimSSMRangePol resource
aci_rest_managed.pimSharedRangePol resource
aci_rest_managed.pimStaticRPEntryPol_fabric_rp resource
aci_rest_managed.pimStaticRPEntryPol_static_rp resource
aci_rest_managed.pimStaticRPPol resource
aci_rest_managed.rtdmcRsFilterToRtMapPol_asm_sg_expiry resource
aci_rest_managed.rtdmcRsFilterToRtMapPol_asm_shared resource
aci_rest_managed.rtdmcRsFilterToRtMapPol_auto_rp resource
aci_rest_managed.rtdmcRsFilterToRtMapPol_bsr resource
aci_rest_managed.rtdmcRsFilterToRtMapPol_fabric_rp resource
aci_rest_managed.rtdmcRsFilterToRtMapPol_pim_inter_vrf resource
aci_rest_managed.rtdmcRsFilterToRtMapPol_ssm_range resource
aci_rest_managed.rtdmcRsFilterToRtMapPol_static_rp resource
aci_rest_managed.vzAny resource
aci_rest_managed.vzRsAnyToCons resource
aci_rest_managed.vzRsAnyToConsIf resource
aci_rest_managed.vzRsAnyToProv resource