public inbox for pve-devel@lists.proxmox.com
 help / color / mirror / Atom feed
From: Gabriel Goller <g.goller@proxmox.com>
To: Stefan Hanreich <s.hanreich@proxmox.com>
Cc: pve-devel@lists.proxmox.com
Subject: Re: [PATCH manager/network/proxmox-ve-rs 0/9] Implement route redistribution for OSPF
Date: Thu, 7 May 2026 13:57:37 +0200	[thread overview]
Message-ID: <ms6kuci6ivp2jthn7tlncqjx4cdbayrfca74v3umchuv23knxx@2bl3vgpnmk7p> (raw)
In-Reply-To: <20260504163157.429628-1-s.hanreich@proxmox.com>

LGTM!
Just a few things:

Setting a route-map on a redistribution didn't work, the api property was
missing:
(pve-network)

diff --git a/src/PVE/Network/SDN/Fabrics.pm b/src/PVE/Network/SDN/Fabrics.pm
index d5ab808c3a..f7140187ad 100644
--- a/src/PVE/Network/SDN/Fabrics.pm
+++ b/src/PVE/Network/SDN/Fabrics.pm
@@ -313,6 +313,12 @@
                                     'static',
                                 ],
                             },
+                            route_map => {
+                                type => 'string',
+                                description =>
+                                    'The route-map to filter the redistribution.',
+                                optional => 1,
+                            },
                         },
                     },
                     optional => 1,


The route_map property also has a wrong serde rename_all type (proxmox-ve-rs):

diff --git a/proxmox-ve-config/src/sdn/fabric/section_config/protocol/ospf.rs b/proxmox-ve-config/src/sdn/fabric/section_config/protocol/ospf.rs
index 2e1f37b278..66297993fe 100644
--- a/proxmox-ve-config/src/sdn/fabric/section_config/protocol/ospf.rs
+++ b/proxmox-ve-config/src/sdn/fabric/section_config/protocol/ospf.rs
@@ -36,7 +36,7 @@

 #[api]
 #[derive(Debug, Clone, Serialize, Deserialize, Hash)]
-#[serde(rename_all = "kebab-case")]
+#[serde(rename_all = "lowercase")]
 /// An OSPF redistribution
 pub struct OspfRedistribution {
     /// The source protocol for this redistribution


There is also an additional whitespace when specifying a route-map:

diff --git a/proxmox-frr-templates/templates/ospfd.jinja b/proxmox-frr-templates/templates/ospfd.jinja
index 4ba609f1e5..427ed7f9dd 100644
--- a/proxmox-frr-templates/templates/ospfd.jinja
+++ b/proxmox-frr-templates/templates/ospfd.jinja
@@ -4,7 +4,7 @@
 router ospf
  ospf router-id {{ ospf.router.router_id }}
 {% for redistribution in ospf.router.redistribute %}
- redistribute {{ redistribution.source }}{% if redistribution.metric is defined %} metric {{ redistribution.metric }}{% endif %} {% if redistribution.route_map is defined %} route-map {{ redistribution.route_map }}{% endif %}
+ redistribute {{ redistribution.source }}{% if redistribution.metric is defined %} metric {{ redistribution.metric }}{% endif %}{% if redistribution.route_map is defined %} route-map {{ redistribution.route_map }}{% endif %}

 {% endfor %}
 exit


And in pve-manager, IMO it looks better when the "Add" button is at the bottom of the table:

diff --git a/www/manager6/sdn/fabrics/RedistributionGrid.js b/www/manager6/sdn/fabrics/RedistributionGrid.js
index 8580c47939..cb7c374d45 100644
--- a/www/manager6/sdn/fabrics/RedistributionGrid.js
+++ b/www/manager6/sdn/fabrics/RedistributionGrid.js
@@ -20,7 +20,7 @@
         }
     },

-    tbar: [
+    bbar: [
         '->',
         {
             text: gettext('Add'),


Another small thing: I'm not sure if "static" is a bit confusing for the users,
because it refers to routes from the "staticd" daemon in frr and not static
routes on the host. But I can't think of a better name to be honest ...

The rest works great!
Tested redistributing every type of routes and tested filtering them by route-maps.




      parent reply	other threads:[~2026-05-07 11:58 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-05-04 16:31 [PATCH manager/network/proxmox-ve-rs 0/9] Implement route redistribution for OSPF Stefan Hanreich
2026-05-04 16:31 ` [PATCH proxmox-ve-rs 1/9] frr: ospf: add redistribute setting Stefan Hanreich
2026-05-04 16:31 ` [PATCH proxmox-ve-rs 2/9] frr-templates: render " Stefan Hanreich
2026-05-04 16:31 ` [PATCH proxmox-ve-rs 3/9] ve-config: add redistribute setting to ospf section config Stefan Hanreich
2026-05-04 16:31 ` [PATCH proxmox-ve-rs 4/9] ve-config: use constructor instead of instantiating struct Stefan Hanreich
2026-05-04 16:31 ` [PATCH proxmox-ve-rs 5/9] ve-config: ospf: generate redistribute config Stefan Hanreich
2026-05-04 16:31 ` [PATCH pve-network 6/9] fabrics: ospf: add redistribute to api types Stefan Hanreich
2026-05-04 16:31 ` [PATCH pve-manager 7/9] ui: sdn: fabrics: add redistribution grid component Stefan Hanreich
2026-05-04 16:31 ` [PATCH pve-manager 8/9] ui: sdn: fabric edit: allow defining multiple tabs Stefan Hanreich
2026-05-04 16:31 ` [PATCH pve-manager 9/9] ui: sdn: ospf fabric: add redistribution grid to ospf fabric Stefan Hanreich
2026-05-07 11:57 ` Gabriel Goller [this message]

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=ms6kuci6ivp2jthn7tlncqjx4cdbayrfca74v3umchuv23knxx@2bl3vgpnmk7p \
    --to=g.goller@proxmox.com \
    --cc=pve-devel@lists.proxmox.com \
    --cc=s.hanreich@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