module ietf-vbras{ namespace "urn:ietf:params:xml:ns:yang:ietf-vbras"; prefix "vbras"; import ietf-interfaces { prefix if; } import ietf-logical-network-element { prefix lne; } /* import ietf-yang-types { prefix yang; } */ organization "IETF NETCONF Working Group"; contact " WG List: Editor: Fangwei Hu "; description "The YANG module defines a generic configuration model for vbras"; revision 2017-04-13 { description "Initial revision"; reference "draft-hu-nfvrg-cu-separation-yang-model-00"; } /* Typedefs */ typedef vlan-id { type uint16 { range "0..4094"; } description "Typedef for VxLAN ID."; } typedef vxlan-id { type uint32; description "Typedef for VxLAN ID."; } typedef address-family-type { type enumeration { enum ipv4 { description "IPv4"; } enum ipv6 { description "IPv6"; } } description "Typedef for address family type."; } /* Configuration Data */ augment /lne:logical-network-elements/lne:logical-network-element { container ietf-vbras{ leaf vbras-name { type string; description "configure vbras name"; } container interfaces { list interface { key name; leaf name { type if:interface-ref; description "interface name"; } container ethernet { leaf lacp { type boolean; description "enable lacp function"; } description "configure ethernet interface"; } leaf mac-offset { type uint32; description "configure mac offset"; } container vlans { list tag { key index; max-elements 2; leaf index { type uint8 { range "0..1"; } must ". = 0 or count(../../tag[index = 0]/index) > 0" { error-message "An inner tag can only be specified if an outer tag has also been specified"; description "Ensure that an inner tag cannot be specified without an outer tag'"; } description "The index into the tag stack, outermost tag assigned index 0"; } container tag{ leaf tag-type { type string; description "tag type"; } leaf vlan-id { type vlan-id; description "vlan id value"; } description "tag"; } description "tag list"; } description "vlans"; } description "interfaces list"; } description "interface container"; } container openflow-channel { leaf ofls-name { type string; description "openflow logical name"; } leaf dpid { type uint32; description "dpid value"; } leaf of-port { type uint32; description "openflow channel udp port number"; } description "configure openflow channel value"; } list vxlan-channel{ key vxlan-tunnel-id; leaf vxlan-tunnel-id { type uint32; description "Static VxLAN tunnel ID."; } leaf vxlan-tunnel-name { type string; description "Name of the static VxLAN tunnel."; } list address-family { key "af"; leaf af { type address-family-type; description "Address family type value."; } leaf tunnel-source-ip { type address-family-type; description "Source IP address for the static VxLAN tunnel"; } leaf tunnel-destination-ip { type address-family-type; description "Destination IP address for the static VxLAN tunnel"; } list bind-vxlan-id { key vxlan-id; leaf vxlan-id { type vxlan-id; description "VxLAN ID."; } description "VxLAN ID list for the VTEP."; } description "Per-af params."; } description "Configure the VxLAN channel"; } description "ietf-vbras configuration!"; } description "augment lne model"; } }