[pbs-devel] [PATCH v2 proxmox-backup 3/6] api2: add optional verify-schdule field to create/update datastore endpoint

Hannes Laimer h.laimer at proxmox.com
Fri Sep 18 11:00:49 CEST 2020


Signed-off-by: Hannes Laimer <h.laimer at proxmox.com>
---
 src/api2/config/datastore.rs | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/src/api2/config/datastore.rs b/src/api2/config/datastore.rs
index 1ee303f8..2fbfda27 100644
--- a/src/api2/config/datastore.rs
+++ b/src/api2/config/datastore.rs
@@ -67,6 +67,10 @@ pub fn list_datastores(
                 optional: true,
                 schema: PRUNE_SCHEDULE_SCHEMA,
             },
+            "verify-schedule": {
+                optional: true,
+                schema: VERIFY_SCHEDULE_SCHEMA,
+            },
             "keep-last": {
                 optional: true,
                 schema: PRUNE_SCHEMA_KEEP_LAST,
@@ -196,6 +200,10 @@ pub enum DeletableProperty {
                 optional: true,
                 schema: PRUNE_SCHEDULE_SCHEMA,
             },
+            "verify-schedule": {
+                optional: true,
+                schema: VERIFY_SCHEDULE_SCHEMA,
+            },
             "keep-last": {
                 optional: true,
                 schema: PRUNE_SCHEMA_KEEP_LAST,
@@ -244,6 +252,7 @@ pub fn update_datastore(
     comment: Option<String>,
     gc_schedule: Option<String>,
     prune_schedule: Option<String>,
+    verify_schedule: Option<String>,
     keep_last: Option<u64>,
     keep_hourly: Option<u64>,
     keep_daily: Option<u64>,
@@ -293,6 +302,7 @@ pub fn update_datastore(
 
     if gc_schedule.is_some() { data.gc_schedule = gc_schedule; }
     if prune_schedule.is_some() { data.prune_schedule = prune_schedule; }
+    if verify_schedule.is_some() { data.verify_schedule = verify_schedule; }
 
     if keep_last.is_some() { data.keep_last = keep_last; }
     if keep_hourly.is_some() { data.keep_hourly = keep_hourly; }
-- 
2.20.1






More information about the pbs-devel mailing list