From: Maximiliano Sandoval <m.sandoval@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [pve-devel] [PATCH cluster 1/1] datacenter config: add replication settings
Date: Thu, 12 Jun 2025 15:29:49 +0200 [thread overview]
Message-ID: <20250612132951.449798-2-m.sandoval@proxmox.com> (raw)
In-Reply-To: <20250612132951.449798-1-m.sandoval@proxmox.com>
Adds replication settings similar to the migration settings. This allows
specifying different networks and it is ultimately more straightforward
than using the migration settings for replication jobs.
Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
---
src/PVE/DataCenterConfig.pm | 32 +++++++++++++++++++++++++++++++-
1 file changed, 31 insertions(+), 1 deletion(-)
diff --git a/src/PVE/DataCenterConfig.pm b/src/PVE/DataCenterConfig.pm
index 53095a1..3d15643 100644
--- a/src/PVE/DataCenterConfig.pm
+++ b/src/PVE/DataCenterConfig.pm
@@ -46,7 +46,27 @@ my $migration_format = {
type => 'string',
format => 'CIDR',
format_description => 'CIDR',
- description => "CIDR of the (sub) network that is used for migration and replication.",
+ description => "CIDR of the (sub) network that is used for migration. "
+ . "Used as a fallback for replications jobs if the replication network setting is not set",
+ },
+};
+
+my $replication_format = {
+ type => {
+ default_key => 1,
+ type => 'string',
+ enum => ['secure', 'insecure'],
+ description => "Replication traffic is encrypted using an SSH tunnel by "
+ . "default. On secure, completely private networks this can be "
+ . "disabled to increase performance.",
+ default => 'secure',
+ },
+ network => {
+ optional => 1,
+ type => 'string',
+ format => 'CIDR',
+ format_description => 'CIDR',
+ description => "CIDR of the (sub) network that is used for replication jobs.",
},
};
@@ -352,6 +372,12 @@ my $datacenter_schema = {
format => $migration_format,
description => "For cluster wide migration settings.",
},
+ replication => {
+ optional => 1,
+ type => 'string',
+ format => $replication_format,
+ description => "For cluster wide replication settings.",
+ },
console => {
optional => 1,
type => 'string',
@@ -506,6 +532,10 @@ sub parse_datacenter_config {
$res->{migration} = parse_property_string($migration_format, $migration);
}
+ if (my $replication = $res->{replication}) {
+ $res->{replication} = parse_property_string($replication_format, $replication);
+ }
+
if (my $next_id = $res->{'next-id'}) {
$res->{'next-id'} = parse_property_string($next_id_format, $next_id);
}
--
2.39.5
_______________________________________________
pve-devel mailing list
pve-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
next prev parent reply other threads:[~2025-06-12 13:30 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-06-12 13:29 [pve-devel] [PATCH cluster/guest-common 0/3] add datacenter replication option Maximiliano Sandoval
2025-06-12 13:29 ` Maximiliano Sandoval [this message]
2025-07-16 14:02 ` [pve-devel] applied: [PATCH cluster 1/1] datacenter config: add replication settings Thomas Lamprecht
2025-06-12 13:29 ` [pve-devel] [PATCH guest-common 1/2] replication: follow datacenter replication options Maximiliano Sandoval
2025-07-17 19:47 ` [pve-devel] applied: " Thomas Lamprecht
2025-06-12 13:29 ` [pve-devel] [PATCH guest-common 2/2] replication: Add used network to log output Maximiliano Sandoval
2025-07-17 19:47 ` [pve-devel] applied: " Thomas Lamprecht
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=20250612132951.449798-2-m.sandoval@proxmox.com \
--to=m.sandoval@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