[pve-devel] [PATCH storage 6/8] pvesm scanthinlvm: make vg optional and add verbose flag

Dominik Csapak d.csapak at proxmox.com
Mon Jul 30 10:26:04 CEST 2018


Signed-off-by: Dominik Csapak <d.csapak at proxmox.com>
---
 PVE/API2/Storage/Scan.pm | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/PVE/API2/Storage/Scan.pm b/PVE/API2/Storage/Scan.pm
index e9ce18e..b1aef3e 100644
--- a/PVE/API2/Storage/Scan.pm
+++ b/PVE/API2/Storage/Scan.pm
@@ -307,7 +307,13 @@ __PACKAGE__->register_method ({
 		type => 'string',
 		pattern => '[a-zA-Z0-9\.\+\_][a-zA-Z0-9\.\+\_\-]+', # see lvm(8) manpage
 		maxLength => 100,
+		optional => 1,
 	    },
+	    verbose => {
+		type => 'boolean',
+		optional => 1,
+		default => 0,
+	    }
 	},
     },
     returns => {
@@ -322,7 +328,7 @@ __PACKAGE__->register_method ({
     code => sub {
 	my ($param) = @_;
 
-	return PVE::Storage::LvmThinPlugin::list_thinpools($param->{vg});
+	return PVE::Storage::LvmThinPlugin::list_thinpools($param->{vg}, $param->{verbose});
     }});
 
 __PACKAGE__->register_method ({
-- 
2.11.0





More information about the pve-devel mailing list