|
|
|
@ -885,3 +885,18 @@ class fillVars(glob_attr):
|
|
|
|
|
return "vmware"
|
|
|
|
|
else:
|
|
|
|
|
return "vesa"
|
|
|
|
|
|
|
|
|
|
def get_cl_kernel_uid(self):
|
|
|
|
|
uuidpath = '/dev/disk/by-uuid'
|
|
|
|
|
if not os.access(uuidpath,os.R_OK):
|
|
|
|
|
return ""
|
|
|
|
|
uuidDevs = filter(os.path.islink,map(lambda x: os.path.join(uuidpath,x),
|
|
|
|
|
os.listdir(uuidpath)))
|
|
|
|
|
mapDevUuid = dict(map(lambda x:(os.path.normpath(os.path.join(uuidpath,
|
|
|
|
|
os.readlink(x))),
|
|
|
|
|
os.path.basename(x)),
|
|
|
|
|
uuidDevs))
|
|
|
|
|
if self.Get('os_root_dev') in mapDevUuid:
|
|
|
|
|
return mapDevUuid[self.Get('os_root_dev')][:8]
|
|
|
|
|
else:
|
|
|
|
|
return ""
|
|
|
|
|