[TRM] Implement VFI/VPLS Support in Terraform Provider #380
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
L2 VFI/VPLS Support
This PR adds support for L2 Virtual Forwarding Instance (VFI) configuration to the terraform-provider-iosxe.
This enhancement introduces the
iosxe_l2_vfiresource and data source with the ability to configure VPLS (Virtual Private LAN Service) instances using manualmode. This feature provides network operators with Layer 2 VPN capabilities, enabling point-to-multipoint Ethernet-based connectivity over MPLS networks. VFI
creates a virtual bridge domain that allows multiple sites to appear as if they are on the same LAN, regardless of their physical location.
CLI Commands Supported
L2 VFI Configuration
l2 vfi {manual | autodiscovery | point-to-point}
vpn id <1-4294967295>
neighbor encapsulation {mpls | l2tpv3}
These commands enable Layer 2 VPN service with the following capabilities:
Benefits
Platform Compatibility
These features have been validated against:
Version Requirements
IOS-XE 17.15.1 and later:
name(String) - VFI instance namemode(String: "manual", "autodiscovery", or "point-to-point") - VFI modevpn_id(Number: 1-4294967295) - VPN identifierneighbors(List) - VFI neighbor configurationip_address(String) - Remote PE router IP addressencapsulation(String: "mpls" or "l2tpv3") - Pseudowire encapsulation typePlatform Notes:
Cisco-IOS-XE-l2vpnYANG model augmented to/native/l2IOSXE1715environment variable tagTechnical Implementation
iosxe_l2_vfiresource with the following attributes:name(String, Required) - VFI instance namemode(String, Optional) - VFI mode: "manual", "autodiscovery", or "point-to-point"vpn_id(Number, Optional) - VPN identifier (range: 1-4294967295)neighbors(List of Objects, Optional) - VFI neighbor pseudowire configurationip_address(String, Required) - Remote PE router IP address (list key)encapsulation(String, Optional) - Encapsulation type ("mpls" or "l2tpv3")iosxe_l2_vfidata source for configuration retrieval/restconf/data/Cisco-IOS-XE-native:native/l2/Cisco-IOS-XE-l2vpn:vfiCisco-IOS-XE-nativeandCisco-IOS-XE-l2vpnmodulestest_tags: [IOSXE1715]skip_minimum_test: truedue to requiredmodeattributeTesting
Go Acceptance Tests
=== RUN TestAccIosxeL2VFI
--- PASS: TestAccIosxeL2VFI (3.10s)
PASS
ok github.com/CiscoDevNet/terraform-provider-iosxe/internal/provider 3.110s
Multi-Platform Validation
Terraform Testing
terraform plan- Correctly identifies VFI configuration changesterraform apply- Successfully applies L2 VFI configurationterraform destroy- Cleanly removes L2 VFI configurationRESTCONF API Validation
Cisco-IOS-XE-l2vpn:vfi)YANG Model Validation
Cisco-IOS-XE-l2vpn.yang)ios-features:l2which is NOT available in IOS-XE 17.12.1config-l2-groupingaugmented to/native/l2router-idkey and encapsulation optionsExample Usage