X-Git-Url: http://git.datanom.net/omvzfs.git/blobdiff_plain/c02535923be4d7f22e8356d3895c0ec43fb56e98..7d6b772c83ecf6ff975233137172688da26568ab:/gui/rpc/zfs.inc diff --git a/gui/rpc/zfs.inc b/gui/rpc/zfs.inc index 28902ed..3bc3ec1 100644 --- a/gui/rpc/zfs.inc +++ b/gui/rpc/zfs.inc @@ -54,9 +54,14 @@ class OMVRpcServiceZFS extends OMVRpcServiceAbstract { throw new OMVModuleZFSException("Incorrect pool type specified"); break; } + //Check for user supplied options + $opts = ""; + if ($params['force']) { + $opts .= "-f "; + } $disks = preg_split("/[,;]/", $params['devices']); $vdev = new OMVModuleZFSVdev($params['name'], $pooltype, $disks); - $pool = new OMVModuleZFSZpool($vdev); + $pool = new OMVModuleZFSZpool($vdev, $opts); //Ugly fix to solve the problem of blkid not displaying info on newly created pools $pool->export(); $pool->import($pool->getName());