ceph-volume: adds has_gpt_headers property to Device class

Signed-off-by: Andrew Schoen <aschoen@redhat.com>

Resolves: rm#27062
This commit is contained in:
Andrew Schoen 2018-11-13 12:27:19 -06:00
parent 3d86d2dda9
commit 568a0ce5be

View File

@ -211,6 +211,10 @@ class Device(object):
def exists(self):
return os.path.exists(self.abspath)
@property
def has_gpt_headers(self):
return self.blkid_api.get("PTTYPE") == "gpt"
@property
def rotational(self):
return self.sys_api['rotational'] == '1'