[pbs-devel] [PATCH proxmox-backup 02/15] config: add uuid+mountpoint to DataStoreConfig
Hannes Laimer
h.laimer at proxmox.com
Thu Aug 19 13:03:30 CEST 2021
Expand the DataStoreConfig to also save the uuid and the
mount-point for removable datastores, a datastore is removable iff both
are set.
---
src/config/datastore.rs | 16 ++++++++++++++++
1 file changed, 16 insertions(+)
diff --git a/src/config/datastore.rs b/src/config/datastore.rs
index 70f03847..92b440c0 100644
--- a/src/config/datastore.rs
+++ b/src/config/datastore.rs
@@ -80,6 +80,16 @@ pub const DIR_NAME_SCHEMA: Schema = StringSchema::new("Directory name").schema()
optional: true,
type: bool,
},
+ "backing-device": {
+ description: "The UUID of the device, iff the datastore is removable.",
+ optional: true,
+ type: String,
+ },
+ "backing-device-mount-point": {
+ description: "The mount point of the device, iff the datastore is removable.",
+ optional: true,
+ type: String,
+ }
}
)]
#[derive(Serialize,Deserialize)]
@@ -115,6 +125,12 @@ pub struct DataStoreConfig {
/// Send notification only for job errors
#[serde(skip_serializing_if="Option::is_none")]
pub notify: Option<String>,
+ /// The UUID of the device(iff removable)
+ #[serde(skip_serializing_if="Option::is_none")]
+ pub backing_device: Option<String>,
+ /// The mount point of the device(iff removable)
+ #[serde(skip_serializing_if="Option::is_none")]
+ pub backing_device_mount_point: Option<String>,
}
fn init() -> SectionConfig {
--
2.30.2
More information about the pbs-devel
mailing list