diff --git a/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/DC1-BL1A.yml b/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/DC1-BL1A.yml
index 2b813ab3d9b..6fe0fef1d72 100644
--- a/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/DC1-BL1A.yml
+++ b/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/DC1-BL1A.yml
@@ -721,10 +721,10 @@ vlan_interfaces:
vrf: TENANT_D_WAN_ZONE
router_ospf:
process_ids:
- - router_id: 192.168.255.14
- id: 14
+ - id: 14
vrf: Tenant_A_WAN_Zone
passive_interface_default: true
+ router_id: 192.168.255.14
no_passive_interfaces:
- Ethernet7
- Vlan150
diff --git a/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/DC1-BL1B.yml b/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/DC1-BL1B.yml
index 40eeb3febe9..892b4cb4a7b 100644
--- a/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/DC1-BL1B.yml
+++ b/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/DC1-BL1B.yml
@@ -689,10 +689,10 @@ vlan_interfaces:
vrf: TENANT_D_WAN_ZONE
router_ospf:
process_ids:
- - router_id: 192.168.255.15
- id: 14
+ - id: 14
vrf: Tenant_A_WAN_Zone
passive_interface_default: true
+ router_id: 192.168.255.15
no_passive_interfaces:
- Vlan150
max_lsa: 15000
diff --git a/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/DC1-LEAF1A.yml b/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/DC1-LEAF1A.yml
index 6090c8e9c67..8193df3fb4c 100644
--- a/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/DC1-LEAF1A.yml
+++ b/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/DC1-LEAF1A.yml
@@ -566,10 +566,10 @@ vlan_interfaces:
vrf: '12345678'
router_ospf:
process_ids:
- - router_id: 192.168.42.42
- id: 9
+ - id: 9
vrf: Tenant_A_OP_Zone
passive_interface_default: true
+ router_id: 192.168.42.42
no_passive_interfaces:
- Vlan113
redistribute:
diff --git a/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/DC1-LEAF2A.yml b/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/DC1-LEAF2A.yml
index f76bc6c8e1c..0ff12004395 100644
--- a/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/DC1-LEAF2A.yml
+++ b/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/DC1-LEAF2A.yml
@@ -1223,10 +1223,10 @@ ipv6_static_routes:
vrf: Tenant_D_OP_Zone
router_ospf:
process_ids:
- - router_id: 192.168.255.10
- id: 16
+ - id: 16
vrf: Tenant_A_OSPF
passive_interface_default: true
+ router_id: 192.168.255.10
no_passive_interfaces:
- Ethernet22
- Ethernet23
diff --git a/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/DC1-LEAF2B.yml b/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/DC1-LEAF2B.yml
index b20664444dc..a7954a3df0a 100644
--- a/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/DC1-LEAF2B.yml
+++ b/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/DC1-LEAF2B.yml
@@ -1163,10 +1163,10 @@ ipv6_static_routes:
vrf: Tenant_D_OP_Zone
router_ospf:
process_ids:
- - router_id: 192.168.255.11
- id: 16
+ - id: 16
vrf: Tenant_A_OSPF
passive_interface_default: true
+ router_id: 192.168.255.11
no_passive_interfaces:
- Ethernet24
redistribute:
diff --git a/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/SVI_PROFILE_NODE_1.yml b/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/SVI_PROFILE_NODE_1.yml
index 0a9f99d7d0c..db900837ce4 100644
--- a/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/SVI_PROFILE_NODE_1.yml
+++ b/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/SVI_PROFILE_NODE_1.yml
@@ -469,10 +469,10 @@ vlan_interfaces:
ospf_network_point_to_point: false
router_ospf:
process_ids:
- - router_id: 192.168.255.1
- id: 1
+ - id: 1
vrf: svi_profile_tests_vrf
passive_interface_default: true
+ router_id: 192.168.255.1
no_passive_interfaces:
- Vlan510
- Vlan511
diff --git a/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/SVI_PROFILE_NODE_2.yml b/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/SVI_PROFILE_NODE_2.yml
index 79a748a9ce9..d58bc7a81de 100644
--- a/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/SVI_PROFILE_NODE_2.yml
+++ b/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/SVI_PROFILE_NODE_2.yml
@@ -341,10 +341,10 @@ vlan_interfaces:
ospf_network_point_to_point: false
router_ospf:
process_ids:
- - router_id: 192.168.255.1
- id: 1
+ - id: 1
vrf: svi_profile_tests_vrf
passive_interface_default: true
+ router_id: 192.168.255.1
no_passive_interfaces:
- Vlan510
- Vlan511
diff --git a/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/bgp-peer-groups-3.yml b/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/bgp-peer-groups-3.yml
index ebdd816b1e8..7aa662dd4d6 100644
--- a/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/bgp-peer-groups-3.yml
+++ b/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/bgp-peer-groups-3.yml
@@ -86,10 +86,10 @@ loopback_interfaces:
node_segment:
ipv4_index: 206
router_isis:
- router_id: 192.168.255.114
instance: CORE
log_adjacency_changes: true
net: 49.0001.1921.6825.5114.00
+ router_id: 192.168.255.114
is_type: level-1-2
address_family_ipv4:
enabled: true
diff --git a/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/core-3-isis-sr-ldp.yml b/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/core-3-isis-sr-ldp.yml
index f6a991ab3bc..f7b5f084a63 100644
--- a/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/core-3-isis-sr-ldp.yml
+++ b/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/core-3-isis-sr-ldp.yml
@@ -42,10 +42,10 @@ loopback_interfaces:
ipv4_index: 203
ipv6_index: 203
router_isis:
- router_id: 10.0.0.3
instance: CORE
log_adjacency_changes: true
net: 49.0001.0100.0000.0003.00
+ router_id: 10.0.0.3
is_type: level-2
address_family_ipv4:
enabled: true
diff --git a/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/evpn_services_l2_only_false.yml b/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/evpn_services_l2_only_false.yml
index 108df07d8d3..1565b1062a6 100644
--- a/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/evpn_services_l2_only_false.yml
+++ b/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/evpn_services_l2_only_false.yml
@@ -993,9 +993,9 @@ vlan_interfaces:
vrf: TENANT_D_WAN_ZONE
router_ospf:
process_ids:
- - router_id: 192.168.255.109
- id: 123
+ - id: 123
passive_interface_default: true
+ router_id: 192.168.255.109
no_passive_interfaces:
- Vlan1234
redistribute:
diff --git a/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/isis-system-id-format-using-node-id.yml b/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/isis-system-id-format-using-node-id.yml
index d1104ea34db..608325f31a0 100644
--- a/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/isis-system-id-format-using-node-id.yml
+++ b/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/isis-system-id-format-using-node-id.yml
@@ -60,10 +60,10 @@ loopback_interfaces:
node_segment:
ipv4_index: 199
router_isis:
- router_id: 172.28.4.99
instance: CORE
log_adjacency_changes: true
net: 49.0001.0000.0001.0099.00
+ router_id: 172.28.4.99
is_type: level-2
address_family_ipv4:
enabled: true
diff --git a/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/isis-system-id-format-using-underlay-loopback.yml b/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/isis-system-id-format-using-underlay-loopback.yml
index 329add55d18..527af085322 100644
--- a/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/isis-system-id-format-using-underlay-loopback.yml
+++ b/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/isis-system-id-format-using-underlay-loopback.yml
@@ -60,10 +60,10 @@ loopback_interfaces:
node_segment:
ipv4_index: 199
router_isis:
- router_id: 172.28.4.99
instance: CORE
log_adjacency_changes: true
net: 49.0001.1720.2800.4099.00
+ router_id: 172.28.4.99
is_type: level-2
address_family_ipv4:
enabled: true
diff --git a/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/l3_edge_isis.yml b/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/l3_edge_isis.yml
index 35da6525c6a..252dff77f71 100644
--- a/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/l3_edge_isis.yml
+++ b/ansible_collections/arista/avd/molecule/eos_designs_unit_tests/intended/structured_configs/l3_edge_isis.yml
@@ -30,10 +30,10 @@ loopback_interfaces:
isis_enable: EVPN_UNDERLAY
isis_passive: true
router_isis:
- router_id: 1.2.3.1
instance: EVPN_UNDERLAY
log_adjacency_changes: true
net: 49.0001.0010.0200.3001.00
+ router_id: 1.2.3.1
is_type: level-2
address_family_ipv4:
enabled: true
diff --git a/ansible_collections/arista/avd/roles/eos_designs/docs/tables/router-general-settings.md b/ansible_collections/arista/avd/roles/eos_designs/docs/tables/router-general-settings.md
deleted file mode 100644
index 6b949d711f1..00000000000
--- a/ansible_collections/arista/avd/roles/eos_designs/docs/tables/router-general-settings.md
+++ /dev/null
@@ -1,22 +0,0 @@
-
-=== "Table"
-
- | Variable | Type | Required | Default | Value Restrictions | Description |
- | -------- | ---- | -------- | ------- | ------------------ | ----------- |
- | [router_general_settings](## "router_general_settings") | Dictionary | | | | |
- | [ router_id](## "router_general_settings.router_id") | Dictionary | | | | |
- | [ ipv4](## "router_general_settings.router_id.ipv4") | String | | | | |
- | [ ipv6](## "router_general_settings.router_id.ipv6") | String | | | | |
-
-=== "YAML"
-
- ```yaml
- router_general_settings:
- router_id:
- ipv4:
- ipv6:
- ```
diff --git a/python-avd/pyavd/_eos_designs/schema/schema_fragments/router_general.schema.yml b/python-avd/pyavd/_eos_designs/schema/schema_fragments/router_general.schema.yml
deleted file mode 100644
index 3014aaab6fe..00000000000
--- a/python-avd/pyavd/_eos_designs/schema/schema_fragments/router_general.schema.yml
+++ /dev/null
@@ -1,18 +0,0 @@
-# Copyright (c) 2023-2024 Arista Networks, Inc.
-# Use of this source code is governed by the Apache License 2.0
-# that can be found in the LICENSE file.
-# yaml-language-server: $schema=../../../_schema/avd_meta_schema.json
-# Line above is used by RedHat's YAML Schema vscode extension
-# Use Ctrl + Space to get suggestions for every field. Autocomplete will pop up after typing 2 letters.
-type: dict
-keys:
- router_general_settings:
- type: dict
- keys:
- router_id:
- type: dict
- keys:
- ipv4:
- type: str
- ipv6:
- type: str
diff --git a/python-avd/pyavd/_eos_designs/schema/schema_fragments/use_router_general_for_router_id.schema.yml b/python-avd/pyavd/_eos_designs/schema/schema_fragments/use_router_general_for_router_id.schema.yml
index 6aa3b541178..e1d110de147 100644
--- a/python-avd/pyavd/_eos_designs/schema/schema_fragments/use_router_general_for_router_id.schema.yml
+++ b/python-avd/pyavd/_eos_designs/schema/schema_fragments/use_router_general_for_router_id.schema.yml
@@ -8,5 +8,5 @@ type: dict
keys:
use_router_general_for_router_id:
type: bool
- description: This setting allows to use `router_id` set under `router_general_settings` as BGP router-id.
+ description: Use `router general` to set router ID for all routing protocols and VRFs.
default: false
diff --git a/python-avd/pyavd/_eos_designs/structured_config/network_services/router_ospf.py b/python-avd/pyavd/_eos_designs/structured_config/network_services/router_ospf.py
index 76326af4550..5281e4fbd4f 100644
--- a/python-avd/pyavd/_eos_designs/structured_config/network_services/router_ospf.py
+++ b/python-avd/pyavd/_eos_designs/structured_config/network_services/router_ospf.py
@@ -62,18 +62,23 @@ def router_ospf(self: AvdStructuredConfigNetworkServices) -> dict | None:
raise AristaAvdInvalidInputsError(msg)
process = {}
- if self.shared_utils.use_router_general_for_router_id is False:
- process["router_id"] = default(get(vrf, "ospf.router_id"), self.shared_utils.router_id)
process.update(
{
"id": process_id,
"vrf": vrf["name"] if vrf["name"] != "default" else None,
"passive_interface_default": True,
+ }
+ )
+ if self.shared_utils.use_router_general_for_router_id is False:
+ process["router_id"] = default(get(vrf, "ospf.router_id"), self.shared_utils.router_id)
+
+ process.update(
+ {
"no_passive_interfaces": ospf_interfaces,
"bfd_enable": get(vrf, "ospf.bfd"),
"max_lsa": get(vrf, "ospf.max_lsa"),
- }
+ }
)
process_redistribute = {}
diff --git a/python-avd/pyavd/_eos_designs/structured_config/underlay/router_isis.py b/python-avd/pyavd/_eos_designs/structured_config/underlay/router_isis.py
index d591fae24a1..ca29046d344 100644
--- a/python-avd/pyavd/_eos_designs/structured_config/underlay/router_isis.py
+++ b/python-avd/pyavd/_eos_designs/structured_config/underlay/router_isis.py
@@ -29,17 +29,23 @@ def router_isis(self: AvdStructuredConfigUnderlay) -> dict | None:
return None
router_isis = {}
- if self.shared_utils.use_router_general_for_router_id is False:
- router_isis["router_id"] = self.shared_utils.router_id
router_isis.update(
{
"instance": self.shared_utils.isis_instance_name,
"log_adjacency_changes": True,
"net": self._isis_net,
+ }
+ )
+
+ if self.shared_utils.use_router_general_for_router_id is False:
+ router_isis["router_id"] = self.shared_utils.router_id
+
+ router_isis.update(
+ {
"is_type": self._is_type,
"address_family_ipv4": {"enabled": True, "maximum_paths": get(self._hostvars, "isis_maximum_paths", default=4)},
- }
+ }
)
if self.shared_utils.underlay_ldp is True: