[master 15/21] If external dependencies are unavailable, cannot support RAID levels.

mulkieran installerbot-noreply at redhat.com
Tue May 12 21:35:57 UTC 2015


From: mulhern <amulhern at redhat.com>

Related: #12

Signed-off-by: mulhern <amulhern at redhat.com>
---
 blivet/devicefactory.py | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/blivet/devicefactory.py b/blivet/devicefactory.py
index 553d011..d2c1a67 100644
--- a/blivet/devicefactory.py
+++ b/blivet/devicefactory.py
@@ -66,7 +66,10 @@ def get_supported_raid_levels(device_type):
     elif device_type == DEVICE_TYPE_MD:
         pkg = mdraid
 
-    return set(pkg.RAID_levels) if pkg else set()
+    if pkg and all(d.available for d in pkg.EXTERNAL_DEPENDENCIES):
+        return set(pkg.RAID_levels)
+    else:
+        return set()
 
 def get_device_type(device):
     # the only time we should ever get a thin pool here is when we're removing


-- 
To view this commit on github, visit https://github.com/rhinstaller/blivet/commit/f1ee7dd3bdb1706f371a834243510faf39395e05


More information about the anaconda-patches mailing list