From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [IPv6:2a01:7e0:0:424::9]) by lore.proxmox.com (Postfix) with ESMTPS id 0B1AF1FF13C for ; Thu, 19 Feb 2026 16:25:03 +0100 (CET) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id CDD541B648; Thu, 19 Feb 2026 16:25:56 +0100 (CET) From: Gabriel Goller To: pve-devel@lists.proxmox.com Subject: [PATCH proxmox-ve-rs v2 1/3] frr: add fabric properties to ISIS types and rename domain Date: Thu, 19 Feb 2026 16:25:21 +0100 Message-ID: <20260219152544.427439-2-g.goller@proxmox.com> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20260219152544.427439-1-g.goller@proxmox.com> References: <20260219152544.427439-1-g.goller@proxmox.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1771514741074 X-SPAM-LEVEL: Spam detection results: 0 AWL -0.003 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment RCVD_IN_VALIDITY_CERTIFIED_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. RCVD_IN_VALIDITY_RPBL_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. RCVD_IN_VALIDITY_SAFE_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to Validity was blocked. See https://knowledge.validity.com/hc/en-us/articles/20961730681243 for more information. SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record Message-ID-Hash: C2ZGZ6ZP7KDARADNJKRAIHEBCV2FUJ2Q X-Message-ID-Hash: C2ZGZ6ZP7KDARADNJKRAIHEBCV2FUJ2Q X-MailFrom: g.goller@proxmox.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.10 Precedence: list List-Id: Proxmox VE development discussion List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: The ISIS types in proxmox-frr are used by pve-network to generate FRR configuration for ISIS controllers. To share these types between ISIS fabric and controller implementations, add properties required by fabrics and rename the "domain" field to "fabric_id" for consistency with fabric terminology. This rename is also applied in pve-network. Signed-off-by: Gabriel Goller --- proxmox-frr-templates/templates/isisd.jinja | 23 +++++++++++--- proxmox-frr/src/ser/isis.rs | 33 +++++++++++++++++++-- proxmox-frr/src/ser/mod.rs | 10 +++++++ 3 files changed, 60 insertions(+), 6 deletions(-) diff --git a/proxmox-frr-templates/templates/isisd.jinja b/proxmox-frr-templates/templates/isisd.jinja index 75f066166ad2..22772dd3886d 100644 --- a/proxmox-frr-templates/templates/isisd.jinja +++ b/proxmox-frr-templates/templates/isisd.jinja @@ -19,11 +19,26 @@ exit {% endfor %} {% for interface_name, interface_config in isis.interfaces|items %} {% call interface(interface_name, interface_config.addresses) %} -{% if interface_config.domain and interface_config.is_ipv4 %} - ip router isis {{ interface_config.domain }} +{% if interface_config.fabric_id and interface_config.is_ipv4 %} + ip router isis {{ interface_config.fabric_id }} {% endif %} -{% if interface_config.domain and interface_config.is_ipv6 %} - ipv6 router isis {{ interface_config.domain }} +{% if interface_config.fabric_id and interface_config.is_ipv6 %} + ipv6 router isis {{ interface_config.fabric_id }} +{% endif %} +{% if interface_config.passive %} + isis passive +{% endif %} +{% if interface_config.hello_interval %} + isis hello-interval {{ interface_config.hello_interval }} +{% endif %} +{% if interface_config.csnp_interval %} + isis csnp-interval {{ interface_config.csnp_interval }} +{% endif %} +{% if interface_config.hello_multiplier %} + isis hello-multiplier {{ interface_config.hello_multiplier }} +{% endif %} +{% if interface_config.point_to_point %} + isis network point-to-point {% endif %} {% for line in interface_config.custom_frr_config %} {{ line }} diff --git a/proxmox-frr/src/ser/isis.rs b/proxmox-frr/src/ser/isis.rs index 2a38a8310fb5..3a48b7612d73 100644 --- a/proxmox-frr/src/ser/isis.rs +++ b/proxmox-frr/src/ser/isis.rs @@ -11,6 +11,18 @@ use crate::ser::FrrWord; #[derive(Clone, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, Serialize, Deserialize)] pub struct IsisRouterName(FrrWord); +impl From for IsisRouterName { + fn from(value: FrrWord) -> Self { + Self(value) + } +} + +impl IsisRouterName { + pub fn new(name: FrrWord) -> Self { + Self(name) + } +} + #[derive(Clone, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, Serialize, Deserialize)] pub enum IsisLevel { #[serde(rename = "level-1")] @@ -27,7 +39,7 @@ pub struct Redistribute { ipv6_connected: IsisLevel, } -#[derive(Clone, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, Serialize, Deserialize, Builder)] pub struct IsisRouter { pub net: Net, #[serde(default, deserialize_with = "proxmox_serde::perl::deserialize_bool")] @@ -39,11 +51,28 @@ pub struct IsisRouter { #[derive(Clone, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, Serialize, Deserialize, Builder)] pub struct IsisInterface { - pub domain: IsisRouterName, + pub fabric_id: IsisRouterName, #[serde(deserialize_with = "proxmox_serde::perl::deserialize_bool")] pub is_ipv4: bool, #[serde(deserialize_with = "proxmox_serde::perl::deserialize_bool")] pub is_ipv6: bool, #[serde(default)] + pub passive: Option, + // Note: openfabric is very similar to isis, so we can use the same properties here + #[serde(default)] + #[builder(required, default = None)] + pub hello_interval: Option, + #[serde(default)] + #[builder(required, default = None)] + pub csnp_interval: Option, + #[serde(default)] + #[builder(required, default = None)] + pub hello_multiplier: Option, + + #[serde(default)] + pub point_to_point: bool, + + #[serde(default)] + #[builder(default)] pub custom_frr_config: Vec, } diff --git a/proxmox-frr/src/ser/mod.rs b/proxmox-frr/src/ser/mod.rs index f3578ef1323a..dfae70cc01e2 100644 --- a/proxmox-frr/src/ser/mod.rs +++ b/proxmox-frr/src/ser/mod.rs @@ -123,6 +123,15 @@ impl From for Interface for Interface { + fn from(value: isis::IsisInterface) -> Self { + Interface { + addresses: Vec::new(), + properties: value, + } + } +} + impl From for Interface { fn from(value: ospf::OspfInterface) -> Self { Interface { @@ -153,6 +162,7 @@ pub struct IpRoute { pub enum FrrProtocol { Ospf, Openfabric, + Isis, Bgp, } -- 2.47.3