From 17409d16862f980f579a32840225f761df65e9ed Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mattias=20Walstr=C3=B6m?= Date: Wed, 3 Jan 2024 16:08:46 +0100 Subject: [PATCH] Add limitation on one area/interface Since this is a limitation in FRR. --- src/confd/yang/infix-routing@2023-11-23.yang | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/confd/yang/infix-routing@2023-11-23.yang b/src/confd/yang/infix-routing@2023-11-23.yang index f1fa86ca..c3d2ec58 100644 --- a/src/confd/yang/infix-routing@2023-11-23.yang +++ b/src/confd/yang/infix-routing@2023-11-23.yang @@ -157,6 +157,14 @@ module infix-routing { } } } + deviation "/ietf-r:routing/ietf-r:control-plane-protocols/ietf-r:control-plane-protocol/ospf:ospf/ospf:areas/ospf:area/ospf:interfaces/ospf:interface" + { + deviate add { + must "current()/name = 'lo' or count(../../../../ospf:areas/ospf:area/ospf:interfaces/ospf:interface[ospf:name=current()/name]) <= 1" { + error-message "Only one area per interface is allowed."; + } + } + } deviation "/ietf-r:routing/ietf-r:ribs/ietf-r:rib/ietf-r:routes/ietf-r:route/ospf:metric" { deviate not-supported;