[pve-devel] [PATCH storage 11/11] Add cifsscan to CLI
Wolfgang Link
w.link at proxmox.com
Tue Mar 13 15:11:11 CET 2018
---
PVE/CLI/pvesm.pm | 13 +++++++++++++
1 file changed, 13 insertions(+)
diff --git a/PVE/CLI/pvesm.pm b/PVE/CLI/pvesm.pm
index 9455595..e6c37ea 100755
--- a/PVE/CLI/pvesm.pm
+++ b/PVE/CLI/pvesm.pm
@@ -331,6 +331,19 @@ our $cmddef = {
printf "%-${maxlen}s %s\n", $rec->{path}, $rec->{options};
}
}],
+ cifsscan => [ "PVE::API2::Storage::Scan", 'cifsscan', ['server'],
+ { node => $nodename }, sub {
+ my $res = shift;
+
+ my $maxlen = 0;
+ foreach my $rec (@$res) {
+ my $len = length ($rec->{share});
+ $maxlen = $len if $len > $maxlen;
+ }
+ foreach my $rec (@$res) {
+ printf "%-${maxlen}s %s\n", $rec->{share}, $rec->{description};
+ }
+ }],
glusterfsscan => [ "PVE::API2::Storage::Scan", 'glusterfsscan', ['server'],
{ node => $nodename }, sub {
my $res = shift;
--
2.11.0
More information about the pve-devel
mailing list