mirror of
git://git.proxmox.com/git/proxmox-backup.git
synced 2025-01-06 13:18:00 +03:00
api: directory: use relative path when creating removable datastore
In an earlier version of this series the datastore path was absolute
for removable datastores. This is simply a leftover that was missed
when changing that to relative paths.
Reported-by: Markus Frank <m.frank@proxmox.com>
Fixes: 94a068e31
("api: node: allow creation of removable datastore through directory endpoint")
Signed-off-by: Hannes Laimer <h.laimer@proxmox.com>
This commit is contained in:
parent
c5c7fd3482
commit
363e32a805
@ -237,7 +237,7 @@ pub fn create_datastore_disk(
|
||||
let lock = pbs_config::datastore::lock_config()?;
|
||||
let datastore: DataStoreConfig = if removable_datastore {
|
||||
serde_json::from_value(
|
||||
json!({ "name": name, "path": format!("/{name}"), "backing-device": uuid }),
|
||||
json!({ "name": name, "path": name, "backing-device": uuid }),
|
||||
)?
|
||||
} else {
|
||||
serde_json::from_value(json!({ "name": name, "path": mount_point }))?
|
||||
|
Loading…
Reference in New Issue
Block a user