jeremmfr / terraform-provider-junos

Terraform provider for Junos devices
https://registry.terraform.io/providers/jeremmfr/junos
MIT License
59 stars 21 forks source link

Feature request: Add support different types of Ethernet encapsulations at the logical interface level #674

Closed Vokunne closed 1 month ago

Vokunne commented 1 month ago

Description

Hi folks,

It'd be great if there is an option to set an encapsulation type for logical interfaces in case of the physical one has encapsulation type flexiable-ethernet-services.

New or Affected Resource(s)

junos_interface_logical

Example Junos Configuration

interfaces {
    xe-0/0/51 {
        flexible-vlan-tagging;
        encapsulation flexible-ethernet-services; 
        unit 100 {
            encapsulation vlan-bridge;
            vlan-id 100;
        }
    }
}

Potential Terraform Configuration

resource "junos_interface_logical" "xe_0_0_15_100" {
  name          = "xe-0/0/051.100"
  vlan_id       = "100"
  encapsulation = "vlan-bridge"
  disable       = null
  description   = "L2 bridge-domain for vlan 15 - sslvpn ha cluster"
}

References

Link to Junos docs - https://www.juniper.net/documentation/us/en/software/junos/interfaces-ethernet-switches/topics/topic-map/switches-interface-flexible.html

jeremmfr commented 1 month ago

Hi 👋

I will take care of adding this.

Vokunne commented 1 month ago

Thanks a lot @jeremmfr