public inbox for pve-devel@lists.proxmox.com
 help / color / mirror / Atom feed
From: Stefan Hanreich <s.hanreich@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [PATCH proxmox-ve-rs v2 1/5] wireguard: add mtu option to wireguard interface properties
Date: Tue, 17 Nov 2026 19:43:40 +0100	[thread overview]
Message-ID: <20261117184346.760458-2-s.hanreich@proxmox.com> (raw)
In-Reply-To: <20261117184346.760458-1-s.hanreich@proxmox.com>

This allows users to explicitly set the MTU that should be configured
for the WireGuard interface.

Signed-off-by: Stefan Hanreich <s.hanreich@proxmox.com>
---
 .../sdn/fabric/section_config/protocol/wireguard.rs | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/proxmox-ve-config/src/sdn/fabric/section_config/protocol/wireguard.rs b/proxmox-ve-config/src/sdn/fabric/section_config/protocol/wireguard.rs
index 8e5df37c..8a7bd734 100644
--- a/proxmox-ve-config/src/sdn/fabric/section_config/protocol/wireguard.rs
+++ b/proxmox-ve-config/src/sdn/fabric/section_config/protocol/wireguard.rs
@@ -532,6 +532,10 @@ pub struct WireGuardInterfaceProperties {
     /// whether to generate an IPv6 link-local address for this interface
     #[serde(skip_serializing_if = "Option::is_none")]
     pub(crate) ip6_ll: Option<bool>,
+
+    /// The MTU for this WireGuard interface.
+    #[serde(skip_serializing_if = "Option::is_none")]
+    pub(crate) mtu: Option<u16>,
 }
 
 impl WireGuardInterfaceProperties {
@@ -554,6 +558,11 @@ impl WireGuardInterfaceProperties {
     pub fn ip6(&self) -> Option<&Ipv6Cidr> {
         self.ip6.as_ref()
     }
+
+    /// Get the MTU set for this interface
+    pub fn mtu(&self) -> Option<u16> {
+        self.mtu
+    }
 }
 
 /// Determines whether the given `PersistentKeepalive` value means that it is
@@ -593,6 +602,10 @@ pub struct WireGuardInterfaceCreateProperties {
     /// whether to generate an IPv6 link-local address for this interface
     #[serde(skip_serializing_if = "Option::is_none")]
     pub(crate) ip6_ll: Option<bool>,
+
+    /// The MTU for this WireGuard interface.
+    #[serde(skip_serializing_if = "Option::is_none")]
+    pub(crate) mtu: Option<u16>,
 }
 
 pub mod private_keys {
-- 
2.47.3





  reply	other threads:[~2026-11-17 18:44 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-17 18:43 [PATCH docs/manager/network/proxmox{-ve-rs,-perl-rs} v2 0/5] Add MTU setting to WireGuard interfaces Stefan Hanreich
2026-11-17 18:43 ` Stefan Hanreich [this message]
2026-11-17 18:43 ` [PATCH proxmox-perl-rs v2 2/5] fabrics: wireguard: render mtu to interface config Stefan Hanreich
2026-11-17 18:43 ` [PATCH pve-network v2 3/5] fabrics: wireguard: add mtu to interface properties Stefan Hanreich
2026-11-17 18:43 ` [PATCH pve-manager v2 4/5] " Stefan Hanreich
2026-11-17 18:43 ` [PATCH pve-docs v2 5/5] sdn: fabrics: wireguard: document mtu option Stefan Hanreich

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=20261117184346.760458-2-s.hanreich@proxmox.com \
    --to=s.hanreich@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