Register CIFSPlugin in the storage plugin system.
This commit is contained in:
committed by
Dietmar Maurer
parent
455f5e1f79
commit
d787523984
@ -25,6 +25,7 @@ use PVE::Storage::DirPlugin;
|
|||||||
use PVE::Storage::LVMPlugin;
|
use PVE::Storage::LVMPlugin;
|
||||||
use PVE::Storage::LvmThinPlugin;
|
use PVE::Storage::LvmThinPlugin;
|
||||||
use PVE::Storage::NFSPlugin;
|
use PVE::Storage::NFSPlugin;
|
||||||
|
use PVE::Storage::CIFSPlugin;
|
||||||
use PVE::Storage::ISCSIPlugin;
|
use PVE::Storage::ISCSIPlugin;
|
||||||
use PVE::Storage::RBDPlugin;
|
use PVE::Storage::RBDPlugin;
|
||||||
use PVE::Storage::SheepdogPlugin;
|
use PVE::Storage::SheepdogPlugin;
|
||||||
@ -42,6 +43,7 @@ PVE::Storage::DirPlugin->register();
|
|||||||
PVE::Storage::LVMPlugin->register();
|
PVE::Storage::LVMPlugin->register();
|
||||||
PVE::Storage::LvmThinPlugin->register();
|
PVE::Storage::LvmThinPlugin->register();
|
||||||
PVE::Storage::NFSPlugin->register();
|
PVE::Storage::NFSPlugin->register();
|
||||||
|
PVE::Storage::CIFSPlugin->register();
|
||||||
PVE::Storage::ISCSIPlugin->register();
|
PVE::Storage::ISCSIPlugin->register();
|
||||||
PVE::Storage::RBDPlugin->register();
|
PVE::Storage::RBDPlugin->register();
|
||||||
PVE::Storage::SheepdogPlugin->register();
|
PVE::Storage::SheepdogPlugin->register();
|
||||||
|
|||||||
@ -19,6 +19,17 @@ our @COMMON_TAR_FLAGS = qw(
|
|||||||
--warning=no-file-ignored --warning=no-xattr-write
|
--warning=no-file-ignored --warning=no-xattr-write
|
||||||
);
|
);
|
||||||
|
|
||||||
|
our @SHARED_STORAGE = (
|
||||||
|
'iscsi',
|
||||||
|
'nfs',
|
||||||
|
'cifs',
|
||||||
|
'rbd',
|
||||||
|
'sheepdog',
|
||||||
|
'iscsidirect',
|
||||||
|
'glusterfs',
|
||||||
|
'zfs',
|
||||||
|
'drbd');
|
||||||
|
|
||||||
cfs_register_file ('storage.cfg',
|
cfs_register_file ('storage.cfg',
|
||||||
sub { __PACKAGE__->parse_config(@_); },
|
sub { __PACKAGE__->parse_config(@_); },
|
||||||
sub { __PACKAGE__->write_config(@_); });
|
sub { __PACKAGE__->write_config(@_); });
|
||||||
@ -331,8 +342,7 @@ sub parse_config {
|
|||||||
if ($def->{content}) {
|
if ($def->{content}) {
|
||||||
$d->{content} = $def->{content}->[1] if !$d->{content};
|
$d->{content} = $def->{content}->[1] if !$d->{content};
|
||||||
}
|
}
|
||||||
|
if (grep { $_ eq $type } @SHARED_STORAGE) {
|
||||||
if ($type eq 'iscsi' || $type eq 'nfs' || $type eq 'rbd' || $type eq 'sheepdog' || $type eq 'iscsidirect' || $type eq 'glusterfs' || $type eq 'zfs' || $type eq 'drbd') {
|
|
||||||
$d->{shared} = 1;
|
$d->{shared} = 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user