Class: MistApi::EvpnOptions
- Defined in:
- lib/mist_api/models/evpn_options.rb
Overview
EVPN Options
Instance Attribute Summary collapse
-
#auto_loopback_subnet ⇒ String
Optional, for dhcp_relay, unique loopback IPs are required for ERB or IPClos where we can set option-82 server_id-overrides.
-
#auto_loopback_subnet6 ⇒ String
Optional, for dhcp_relay, unique loopback IPs are required for ERB or IPClos where we can set option-82 server_id-overrides.
-
#auto_router_id_subnet ⇒ String
Optional, this generates router_id automatically, if specified, ‘router_id_prefix` is ignored.
-
#auto_router_id_subnet6 ⇒ String
Optional, this generates router_id automatically, if specified, ‘router_id_prefix` is ignored.
-
#core_as_border ⇒ TrueClass | FalseClass
Optional, for ERB or CLOS, you can either use esilag to upstream routers or to also be the virtual-gateway.
-
#enable_inband_mgmt ⇒ TrueClass | FalseClass
Whether to route management traffic inband; routes will be propagated to downstream switches.
-
#enable_inband_ztp ⇒ TrueClass | FalseClass
if the mangement traffic goes inbnd, during installation, only the border/core switches are connected to the Internet to allow initial configuration to be pushed down and leave the downstream access switches stay in the Factory Default state enabling inband-ztp allows upstream switches to use LLDP to assign IP and gives Internet to downstream switches in that state.
-
#overlay ⇒ EvpnOptionsOverlay
if the mangement traffic goes inbnd, during installation, only the border/core switches are connected to the Internet to allow initial configuration to be pushed down and leave the downstream access switches stay in the Factory Default state enabling inband-ztp allows upstream switches to use LLDP to assign IP and gives Internet to downstream switches in that state.
-
#per_vlan_vga_v4_mac ⇒ TrueClass | FalseClass
Only for by Core-Distribution architecture when ‘evpn_options.routed_at`==`core`.
-
#per_vlan_vga_v6_mac ⇒ TrueClass | FalseClass
Only for by Core-Distribution architecture when ‘evpn_options.routed_at`==`core`.
-
#routed_at ⇒ EvpnOptionsRoutedAtEnum
optional, where virtual-gateway should reside.
-
#underlay ⇒ EvpnOptionsUnderlay
optional, where virtual-gateway should reside.
-
#vs_instances ⇒ Hash[String, EvpnOptionsVsInstance]
Optional, for EX9200 only to segregate virtual-switches.
Class Method Summary collapse
-
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
-
.names ⇒ Object
A mapping from model property names to API property names.
-
.nullables ⇒ Object
An array for nullable fields.
-
.optionals ⇒ Object
An array for optional fields.
Instance Method Summary collapse
-
#initialize(auto_loopback_subnet = '172.16.192.0/24', auto_loopback_subnet6 = 'fd33:ab00:2::/64', auto_router_id_subnet = '172.16.254.0/23', auto_router_id_subnet6 = SKIP, core_as_border = false, enable_inband_mgmt = false, enable_inband_ztp = false, overlay = SKIP, per_vlan_vga_v4_mac = false, per_vlan_vga_v6_mac = false, routed_at = EvpnOptionsRoutedAtEnum::EDGE, underlay = SKIP, vs_instances = SKIP) ⇒ EvpnOptions
constructor
A new instance of EvpnOptions.
-
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
-
#to_s ⇒ Object
Provides a human-readable string representation of the object.
Methods inherited from BaseModel
#check_for_conflict, #process_additional_properties, #process_array, #process_basic_value, #process_hash, #to_hash, #to_json
Constructor Details
#initialize(auto_loopback_subnet = '172.16.192.0/24', auto_loopback_subnet6 = 'fd33:ab00:2::/64', auto_router_id_subnet = '172.16.254.0/23', auto_router_id_subnet6 = SKIP, core_as_border = false, enable_inband_mgmt = false, enable_inband_ztp = false, overlay = SKIP, per_vlan_vga_v4_mac = false, per_vlan_vga_v6_mac = false, routed_at = EvpnOptionsRoutedAtEnum::EDGE, underlay = SKIP, vs_instances = SKIP) ⇒ EvpnOptions
Returns a new instance of EvpnOptions.
132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 |
# File 'lib/mist_api/models/evpn_options.rb', line 132 def initialize(auto_loopback_subnet = '172.16.192.0/24', auto_loopback_subnet6 = 'fd33:ab00:2::/64', auto_router_id_subnet = '172.16.254.0/23', auto_router_id_subnet6 = SKIP, core_as_border = false, enable_inband_mgmt = false, enable_inband_ztp = false, = SKIP, per_vlan_vga_v4_mac = false, per_vlan_vga_v6_mac = false, routed_at = EvpnOptionsRoutedAtEnum::EDGE, underlay = SKIP, vs_instances = SKIP) @auto_loopback_subnet = auto_loopback_subnet unless auto_loopback_subnet == SKIP @auto_loopback_subnet6 = auto_loopback_subnet6 unless auto_loopback_subnet6 == SKIP @auto_router_id_subnet = auto_router_id_subnet unless auto_router_id_subnet == SKIP @auto_router_id_subnet6 = auto_router_id_subnet6 unless auto_router_id_subnet6 == SKIP @core_as_border = core_as_border unless core_as_border == SKIP @enable_inband_mgmt = enable_inband_mgmt unless enable_inband_mgmt == SKIP @enable_inband_ztp = enable_inband_ztp unless enable_inband_ztp == SKIP @overlay = unless == SKIP @per_vlan_vga_v4_mac = per_vlan_vga_v4_mac unless per_vlan_vga_v4_mac == SKIP @per_vlan_vga_v6_mac = per_vlan_vga_v6_mac unless per_vlan_vga_v6_mac == SKIP @routed_at = routed_at unless routed_at == SKIP @underlay = underlay unless underlay == SKIP @vs_instances = vs_instances unless vs_instances == SKIP end |
Instance Attribute Details
#auto_loopback_subnet ⇒ String
Optional, for dhcp_relay, unique loopback IPs are required for ERB or IPClos where we can set option-82 server_id-overrides
15 16 17 |
# File 'lib/mist_api/models/evpn_options.rb', line 15 def auto_loopback_subnet @auto_loopback_subnet end |
#auto_loopback_subnet6 ⇒ String
Optional, for dhcp_relay, unique loopback IPs are required for ERB or IPClos where we can set option-82 server_id-overrides
20 21 22 |
# File 'lib/mist_api/models/evpn_options.rb', line 20 def auto_loopback_subnet6 @auto_loopback_subnet6 end |
#auto_router_id_subnet ⇒ String
Optional, this generates router_id automatically, if specified, ‘router_id_prefix` is ignored
25 26 27 |
# File 'lib/mist_api/models/evpn_options.rb', line 25 def auto_router_id_subnet @auto_router_id_subnet end |
#auto_router_id_subnet6 ⇒ String
Optional, this generates router_id automatically, if specified, ‘router_id_prefix` is ignored
30 31 32 |
# File 'lib/mist_api/models/evpn_options.rb', line 30 def auto_router_id_subnet6 @auto_router_id_subnet6 end |
#core_as_border ⇒ TrueClass | FalseClass
Optional, for ERB or CLOS, you can either use esilag to upstream routers or to also be the virtual-gateway. When ‘routed_at` != `core`, whether to do virtual-gateway at core as well
36 37 38 |
# File 'lib/mist_api/models/evpn_options.rb', line 36 def core_as_border @core_as_border end |
#enable_inband_mgmt ⇒ TrueClass | FalseClass
Whether to route management traffic inband; routes will be propagated to downstream switches
41 42 43 |
# File 'lib/mist_api/models/evpn_options.rb', line 41 def enable_inband_mgmt @enable_inband_mgmt end |
#enable_inband_ztp ⇒ TrueClass | FalseClass
if the mangement traffic goes inbnd, during installation, only the border/core switches are connected to the Internet to allow initial configuration to be pushed down and leave the downstream access switches stay in the Factory Default state enabling inband-ztp allows upstream switches to use LLDP to assign IP and gives Internet to downstream switches in that state
50 51 52 |
# File 'lib/mist_api/models/evpn_options.rb', line 50 def enable_inband_ztp @enable_inband_ztp end |
#overlay ⇒ EvpnOptionsOverlay
if the mangement traffic goes inbnd, during installation, only the border/core switches are connected to the Internet to allow initial configuration to be pushed down and leave the downstream access switches stay in the Factory Default state enabling inband-ztp allows upstream switches to use LLDP to assign IP and gives Internet to downstream switches in that state
59 60 61 |
# File 'lib/mist_api/models/evpn_options.rb', line 59 def @overlay end |
#per_vlan_vga_v4_mac ⇒ TrueClass | FalseClass
Only for by Core-Distribution architecture when ‘evpn_options.routed_at`==`core`. By default, JUNOS uses 00-00-5e-00-01-01 as the virtual-gateway-address’s v4_mac. If enabled, 00-00-5e-00-0X-YY will be used (where XX=vlan_id/256, YY=vlan_id%256)
66 67 68 |
# File 'lib/mist_api/models/evpn_options.rb', line 66 def per_vlan_vga_v4_mac @per_vlan_vga_v4_mac end |
#per_vlan_vga_v6_mac ⇒ TrueClass | FalseClass
Only for by Core-Distribution architecture when ‘evpn_options.routed_at`==`core`. By default, JUNOS uses 00-00-5e-00-02-01 as the virtual-gateway-address’s v6_mac. If enabled, 00-00-5e-00-1X-YY will be used (where XX=vlan_id/256, YY=vlan_id%256)
73 74 75 |
# File 'lib/mist_api/models/evpn_options.rb', line 73 def per_vlan_vga_v6_mac @per_vlan_vga_v6_mac end |
#routed_at ⇒ EvpnOptionsRoutedAtEnum
optional, where virtual-gateway should reside. enum: ‘core`, `distribution`, `edge`
78 79 80 |
# File 'lib/mist_api/models/evpn_options.rb', line 78 def routed_at @routed_at end |
#underlay ⇒ EvpnOptionsUnderlay
optional, where virtual-gateway should reside. enum: ‘core`, `distribution`, `edge`
83 84 85 |
# File 'lib/mist_api/models/evpn_options.rb', line 83 def underlay @underlay end |
#vs_instances ⇒ Hash[String, EvpnOptionsVsInstance]
Optional, for EX9200 only to segregate virtual-switches
87 88 89 |
# File 'lib/mist_api/models/evpn_options.rb', line 87 def vs_instances @vs_instances end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 |
# File 'lib/mist_api/models/evpn_options.rb', line 157 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. auto_loopback_subnet = hash['auto_loopback_subnet'] ||= '172.16.192.0/24' auto_loopback_subnet6 = hash['auto_loopback_subnet6'] ||= 'fd33:ab00:2::/64' auto_router_id_subnet = hash['auto_router_id_subnet'] ||= '172.16.254.0/23' auto_router_id_subnet6 = hash.key?('auto_router_id_subnet6') ? hash['auto_router_id_subnet6'] : SKIP core_as_border = hash['core_as_border'] ||= false enable_inband_mgmt = hash['enable_inband_mgmt'] ||= false enable_inband_ztp = hash['enable_inband_ztp'] ||= false = EvpnOptionsOverlay.from_hash(hash['overlay']) if hash['overlay'] per_vlan_vga_v4_mac = hash['per_vlan_vga_v4_mac'] ||= false per_vlan_vga_v6_mac = hash['per_vlan_vga_v6_mac'] ||= false routed_at = hash['routed_at'] ||= EvpnOptionsRoutedAtEnum::EDGE underlay = EvpnOptionsUnderlay.from_hash(hash['underlay']) if hash['underlay'] vs_instances = EvpnOptionsVsInstance.from_hash(hash['vs_instances']) if hash['vs_instances'] vs_instances = SKIP unless hash.key?('vs_instances') # Create object from extracted values. EvpnOptions.new(auto_loopback_subnet, auto_loopback_subnet6, auto_router_id_subnet, auto_router_id_subnet6, core_as_border, enable_inband_mgmt, enable_inband_ztp, , per_vlan_vga_v4_mac, per_vlan_vga_v6_mac, routed_at, underlay, vs_instances) end |
.names ⇒ Object
A mapping from model property names to API property names.
90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 |
# File 'lib/mist_api/models/evpn_options.rb', line 90 def self.names @_hash = {} if @_hash.nil? @_hash['auto_loopback_subnet'] = 'auto_loopback_subnet' @_hash['auto_loopback_subnet6'] = 'auto_loopback_subnet6' @_hash['auto_router_id_subnet'] = 'auto_router_id_subnet' @_hash['auto_router_id_subnet6'] = 'auto_router_id_subnet6' @_hash['core_as_border'] = 'core_as_border' @_hash['enable_inband_mgmt'] = 'enable_inband_mgmt' @_hash['enable_inband_ztp'] = 'enable_inband_ztp' @_hash['overlay'] = 'overlay' @_hash['per_vlan_vga_v4_mac'] = 'per_vlan_vga_v4_mac' @_hash['per_vlan_vga_v6_mac'] = 'per_vlan_vga_v6_mac' @_hash['routed_at'] = 'routed_at' @_hash['underlay'] = 'underlay' @_hash['vs_instances'] = 'vs_instances' @_hash end |
.nullables ⇒ Object
An array for nullable fields
128 129 130 |
# File 'lib/mist_api/models/evpn_options.rb', line 128 def self.nullables [] end |
.optionals ⇒ Object
An array for optional fields
109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 |
# File 'lib/mist_api/models/evpn_options.rb', line 109 def self.optionals %w[ auto_loopback_subnet auto_loopback_subnet6 auto_router_id_subnet auto_router_id_subnet6 core_as_border enable_inband_mgmt enable_inband_ztp overlay per_vlan_vga_v4_mac per_vlan_vga_v6_mac routed_at underlay vs_instances ] end |
Instance Method Details
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
209 210 211 212 213 214 215 216 217 218 219 220 |
# File 'lib/mist_api/models/evpn_options.rb', line 209 def inspect class_name = self.class.name.split('::').last "<#{class_name} auto_loopback_subnet: #{@auto_loopback_subnet.inspect},"\ " auto_loopback_subnet6: #{@auto_loopback_subnet6.inspect}, auto_router_id_subnet:"\ " #{@auto_router_id_subnet.inspect}, auto_router_id_subnet6:"\ " #{@auto_router_id_subnet6.inspect}, core_as_border: #{@core_as_border.inspect},"\ " enable_inband_mgmt: #{@enable_inband_mgmt.inspect}, enable_inband_ztp:"\ " #{@enable_inband_ztp.inspect}, overlay: #{@overlay.inspect}, per_vlan_vga_v4_mac:"\ " #{@per_vlan_vga_v4_mac.inspect}, per_vlan_vga_v6_mac: #{@per_vlan_vga_v6_mac.inspect},"\ " routed_at: #{@routed_at.inspect}, underlay: #{@underlay.inspect}, vs_instances:"\ " #{@vs_instances.inspect}>" end |
#to_s ⇒ Object
Provides a human-readable string representation of the object.
197 198 199 200 201 202 203 204 205 206 |
# File 'lib/mist_api/models/evpn_options.rb', line 197 def to_s class_name = self.class.name.split('::').last "<#{class_name} auto_loopback_subnet: #{@auto_loopback_subnet}, auto_loopback_subnet6:"\ " #{@auto_loopback_subnet6}, auto_router_id_subnet: #{@auto_router_id_subnet},"\ " auto_router_id_subnet6: #{@auto_router_id_subnet6}, core_as_border: #{@core_as_border},"\ " enable_inband_mgmt: #{@enable_inband_mgmt}, enable_inband_ztp: #{@enable_inband_ztp},"\ " overlay: #{@overlay}, per_vlan_vga_v4_mac: #{@per_vlan_vga_v4_mac}, per_vlan_vga_v6_mac:"\ " #{@per_vlan_vga_v6_mac}, routed_at: #{@routed_at}, underlay: #{@underlay}, vs_instances:"\ " #{@vs_instances}>" end |