From: Hannes Laimer <h.laimer@proxmox.com>
To: pbs-devel@lists.proxmox.com
Subject: [pbs-devel] [PATCH proxmox-backup 3/4] fix #4256: api2: remove datastore ACL-node on removal of datastore
Date: Mon, 19 Dec 2022 15:13:25 +0100 [thread overview]
Message-ID: <20221219141326.201199-4-h.laimer@proxmox.com> (raw)
In-Reply-To: <20221219141326.201199-1-h.laimer@proxmox.com>
Signed-off-by: Hannes Laimer <h.laimer@proxmox.com>
---
src/api2/config/datastore.rs | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/src/api2/config/datastore.rs b/src/api2/config/datastore.rs
index 27489590..677650b9 100644
--- a/src/api2/config/datastore.rs
+++ b/src/api2/config/datastore.rs
@@ -440,6 +440,10 @@ pub async fn delete_datastore(
delete_prune_job(job.config.id, None, rpcenv)?
}
+ let (mut tree, _digest) = pbs_config::acl::config()?;
+ tree.delete_node(&format!("/datastore/{}", name));
+ pbs_config::acl::save_config(&tree)?;
+
let tape_jobs = list_tape_backup_jobs(Value::Null, rpcenv)?;
for job_config in tape_jobs
.into_iter()
--
2.30.2
next prev parent reply other threads:[~2022-12-19 14:14 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-12-19 14:13 [pbs-devel] [PATCH proxmox-backup 0/4] fix #4256: remove datastore from configs after deletion Hannes Laimer
2022-12-19 14:13 ` [pbs-devel] [PATCH proxmox-backup 1/4] fix #4256: api2: remove prune jobs on datastore delete Hannes Laimer
2022-12-19 14:13 ` [pbs-devel] [PATCH proxmox-backup 2/4] pbs-config: add delete_node for ACL-tree Hannes Laimer
2022-12-19 14:13 ` Hannes Laimer [this message]
2022-12-19 14:13 ` [pbs-devel] [PATCH proxmox-backup 4/4] ui: add 'keep configs' checkbox to datastore removal window Hannes Laimer
2022-12-20 9:37 ` Wolfgang Bumiller
2022-12-20 9:36 ` [pbs-devel] partially-applied: [PATCH proxmox-backup 0/4] fix #4256: remove datastore from configs after deletion Wolfgang Bumiller
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=20221219141326.201199-4-h.laimer@proxmox.com \
--to=h.laimer@proxmox.com \
--cc=pbs-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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal