public inbox for pve-devel@lists.proxmox.com
 help / color / mirror / Atom feed
From: Gabriel Goller <g.goller@proxmox.com>
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	[thread overview]
Message-ID: <20260219152544.427439-2-g.goller@proxmox.com> (raw)
In-Reply-To: <20260219152544.427439-1-g.goller@proxmox.com>

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 <g.goller@proxmox.com>
---
 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<FrrWord> 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<bool>,
+    // 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<proxmox_sdn_types::openfabric::HelloInterval>,
+    #[serde(default)]
+    #[builder(required, default = None)]
+    pub csnp_interval: Option<proxmox_sdn_types::openfabric::CsnpInterval>,
+    #[serde(default)]
+    #[builder(required, default = None)]
+    pub hello_multiplier: Option<proxmox_sdn_types::openfabric::HelloMultiplier>,
+
+    #[serde(default)]
+    pub point_to_point: bool,
+
+    #[serde(default)]
+    #[builder(default)]
     pub custom_frr_config: Vec<String>,
 }
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<openfabric::OpenfabricInterface> for Interface<openfabric::OpenfabricI
     }
 }
 
+impl From<isis::IsisInterface> for Interface<isis::IsisInterface> {
+    fn from(value: isis::IsisInterface) -> Self {
+        Interface {
+            addresses: Vec::new(),
+            properties: value,
+        }
+    }
+}
+
 impl From<ospf::OspfInterface> for Interface<ospf::OspfInterface> {
     fn from(value: ospf::OspfInterface) -> Self {
         Interface {
@@ -153,6 +162,7 @@ pub struct IpRoute {
 pub enum FrrProtocol {
     Ospf,
     Openfabric,
+    Isis,
     Bgp,
 }
 
-- 
2.47.3





  reply	other threads:[~2026-02-19 15:25 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-02-19 15:25 [PATCH docs/gui-tests/manager/network/proxmox{-ve-rs,-perl-rs} v2 00/11] Add IS-IS protocol to fabrics Gabriel Goller
2026-02-19 15:25 ` Gabriel Goller [this message]
2026-02-19 15:25 ` [PATCH proxmox-ve-rs v2 2/3] ve-config: add IS-IS fabric config parsing and frr config generation Gabriel Goller
2026-02-19 15:25 ` [PATCH proxmox-ve-rs v2 3/3] ve-config: add integration tests for IS-IS fabrics Gabriel Goller
2026-02-19 15:25 ` [PATCH proxmox-perl-rs v2 1/2] pve-rs: fabrics: add IS-IS protocol ifupdown config generation Gabriel Goller
2026-02-19 15:25 ` [PATCH proxmox-perl-rs v2 2/2] sdn: add IS-IS fabric status reporting Gabriel Goller
2026-02-19 15:25 ` [PATCH pve-network v2 1/2] fabrics: add IS-IS api types Gabriel Goller
2026-02-19 15:25 ` [PATCH pve-network v2 2/2] sdn: controllers: rename isis domain to fabric_id Gabriel Goller
2026-02-19 15:25 ` [PATCH pve-manager v2 1/2] fabrics: add IS-IS panels Gabriel Goller
2026-02-19 15:25 ` [PATCH pve-manager v2 2/2] sdn: add warning about IS-IS controller deprecation Gabriel Goller
2026-02-19 15:25 ` [PATCH pve-docs v2 1/1] sdn: add section about IS-IS fabric Gabriel Goller
2026-02-19 15:25 ` [PATCH pve-gui-tests v2 1/1] fabrics: add screenshots for IS-IS fabric and nodes Gabriel Goller

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260219152544.427439-2-g.goller@proxmox.com \
    --to=g.goller@proxmox.com \
    --cc=pve-devel@lists.proxmox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal