From: Thomas Lamprecht <t.lamprecht@proxmox.com>
To: Proxmox VE development discussion <pve-devel@lists.proxmox.com>,
Aaron Lauterer <a.lauterer@proxmox.com>
Subject: Re: [pve-devel] [PATCH v2 storage 2/2] Ceph: add keyring parameter for external clusters
Date: Thu, 26 Aug 2021 11:25:29 +0200 [thread overview]
Message-ID: <a79d9e76-02a1-90e2-ba70-38ca2200a89f@proxmox.com> (raw)
In-Reply-To: <20210803114556.3354407-3-a.lauterer@proxmox.com>
On 03/08/2021 13:45, Aaron Lauterer wrote:
patch does not applies..
> diff --git a/PVE/Storage/RBDPlugin.pm b/PVE/Storage/RBDPlugin.pm
> index a8d1243..4bd43d5 100644
> --- a/PVE/Storage/RBDPlugin.pm
> +++ b/PVE/Storage/RBDPlugin.pm
.. snip
> @@ -327,20 +332,29 @@ sub options {
diff # do not seem to match even with below bogus `gg` line removed
> sub on_add_hook {
> my ($class, $storeid, $scfg, %param) = @_;
>
> - return if defined($scfg->{monhost}); # nothing to do if not pve managed ceph
> + my $secret = $param{keyring} if defined $param{keyring} // undef;
> + PVE::CephConfig::ceph_create_keyfile($scfg->{type}, $storeid, $secret);
>
> - PVE::CephConfig::ceph_create_keyfile($scfg->{type}, $storeid);
> + return;
> +}
> +
> +sub on_update_hook {
> + my ($class, $storeid, $scfg, %param) = @_;
> +
> + if (exists($param{keyring})) {
> + if (defined($param{keyring})) {
> + PVE::CephConfig::ceph_create_keyfile($scfg->{type}, $storeid, $param{keyring});
> + } else {
> + PVE::CephConfig::ceph_remove_keyfile($scfg->{type}, $storeid);
> + }
> + }
> gg
bogus line above, probably from a vim-go-to-top in insert mode mistake..
> return;
> }
>
> sub on_delete_hook {
> my ($class, $storeid, $scfg) = @_;
> -
> - return if defined($scfg->{monhost}); # nothing to do if not pve managed ceph
> -
> PVE::CephConfig::ceph_remove_keyfile($scfg->{type}, $storeid);
> -
> return;
> }
>
>
prev parent reply other threads:[~2021-08-26 9:26 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-08-03 11:45 [pve-devel] [PATCH v2 storage 0/2] RBD/Cephfs: new keyring parameter Aaron Lauterer
2021-08-03 11:45 ` [pve-devel] [PATCH v2 storage 1/2] CephConfig: add optional $secret parameter Aaron Lauterer
2021-08-03 11:45 ` [pve-devel] [PATCH v2 storage 2/2] Ceph: add keyring parameter for external clusters Aaron Lauterer
2021-08-26 9:25 ` Thomas Lamprecht [this message]
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=a79d9e76-02a1-90e2-ba70-38ca2200a89f@proxmox.com \
--to=t.lamprecht@proxmox.com \
--cc=a.lauterer@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 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.