iscsi direct plugin: implement method to get qemu blockdevice options
Signed-off-by: Fiona Ebner <f.ebner@proxmox.com>
This commit is contained in:
committed by
Fabian Grünbichler
parent
073c5677c7
commit
c136eb76c7
@ -110,6 +110,20 @@ sub path {
|
|||||||
return ($path, $vmid, $vtype);
|
return ($path, $vmid, $vtype);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
sub qemu_blockdev_options {
|
||||||
|
my ($class, $scfg, $storeid, $volname) = @_;
|
||||||
|
|
||||||
|
my $lun = ($class->parse_volname($volname))[1];
|
||||||
|
|
||||||
|
return {
|
||||||
|
driver => 'iscsi',
|
||||||
|
transport => 'tcp',
|
||||||
|
portal => "$scfg->{portal}",
|
||||||
|
target => "$scfg->{target}",
|
||||||
|
lun => int($lun),
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
sub create_base {
|
sub create_base {
|
||||||
my ($class, $storeid, $scfg, $volname) = @_;
|
my ($class, $storeid, $scfg, $volname) = @_;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user