]> git.proxmox.com Git - pve-manager.git/blobdiff - PVE/API2/Ceph.pm
ceph: init: allow pool deletion by default
[pve-manager.git] / PVE / API2 / Ceph.pm
index 9a321b0ef4b8fd12188a9b461367d15791d4699d..89b8eb5b1af3d067e379bcec7d7892d6b16e6c7f 100644 (file)
@@ -721,7 +721,7 @@ __PACKAGE__->register_method ({
                default => 2,
                optional => 1,
                minimum => 1,
-               maximum => 3,
+               maximum => 7,
            },
            pg_bits => {
                description => "Placement group bits, used to specify the " .
@@ -733,6 +733,15 @@ __PACKAGE__->register_method ({
                minimum => 6,
                maximum => 14,
            },
+           disable_cephx => {
+               description => "Disable cephx authentification.\n\n" .
+                   "WARNING: cephx is a security feature protecting against " .
+                   "man-in-the-middle attacks. Only consider disabling cephx ".
+                   "if your network is private!",
+               type => 'boolean',
+               optional => 1,
+               default => 0,
+           },
        },
     },
     returns => { type => 'null' },
@@ -752,14 +761,16 @@ __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',
-               'filestore xattr use omap' => 'true',
+               '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,
+               'mon allow pool delete' => 'true',
            };
 
            # this does not work for default pools 
@@ -1243,7 +1254,7 @@ __PACKAGE__->register_method ({
                default => 2,
                optional => 1,
                minimum => 1,
-               maximum => 3,
+               maximum => 7,
            },
            min_size => {
                description => 'Minimum number of replicas per object',
@@ -1251,7 +1262,7 @@ __PACKAGE__->register_method ({
                default => 1,
                optional => 1,
                minimum => 1,
-               maximum => 3,
+               maximum => 7,
            },
            pg_num => {
                description => "Number of placement groups.",