]> git.proxmox.com Git - pve-manager.git/commitdiff
ceph: init: add optional disable-cephx option
authorAlexandre Derumier <aderumier@odiso.com>
Fri, 28 Apr 2017 07:52:59 +0000 (09:52 +0200)
committerFabian Grünbichler <f.gruenbichler@proxmox.com>
Wed, 3 May 2017 08:27:18 +0000 (10:27 +0200)
Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
PVE/API2/Ceph.pm

index 6ffa528ec23e902e0b68825be1baa2e48219c2da..4f853f3d09dc127fcfe0f9b0f1c95e5a64070b92 100644 (file)
@@ -733,6 +733,12 @@ __PACKAGE__->register_method ({
                minimum => 6,
                maximum => 14,
            },
+           'disable-cephx' => {
+               description => "Disable cephx authentification.",
+               type => 'boolean',
+               optional => 1,
+               default => 0,
+           }
        },
     },
     returns => { type => 'null' },
@@ -752,11 +758,13 @@ __PACKAGE__->register_method ({
            UUID::generate($uuid);
            UUID::unparse($uuid, $fsid);
 
+           my $auth = $param->{'disable-cephx'} ? 'none' : 'cephx';
+
            $cfg->{global} = {
                'fsid' => $fsid,
-               'auth cluster required' => 'cephx',
-               'auth service required' => 'cephx',
-               'auth client required' => 'cephx',
+               'auth cluster required' => $auth,
+               'auth service required' => $auth,
+               'auth client required' => $auth,
                'osd journal size' => $pve_osd_default_journal_size,
                'osd pool default min size' => 1,
            };