|
|
|
@ -645,8 +645,6 @@ class Facts(object):
|
|
|
|
|
self.facts['lsb']['release'] = value
|
|
|
|
|
elif 'Codename:' in line:
|
|
|
|
|
self.facts['lsb']['codename'] = value
|
|
|
|
|
if 'lsb' in self.facts and 'release' in self.facts['lsb']:
|
|
|
|
|
self.facts['lsb']['major_release'] = self.facts['lsb']['release'].split('.')[0]
|
|
|
|
|
elif lsb_path is None and os.path.exists('/etc/lsb-release'):
|
|
|
|
|
self.facts['lsb'] = {}
|
|
|
|
|
for line in get_file_lines('/etc/lsb-release'):
|
|
|
|
@ -659,13 +657,10 @@ class Facts(object):
|
|
|
|
|
self.facts['lsb']['description'] = value
|
|
|
|
|
elif 'DISTRIB_CODENAME' in line:
|
|
|
|
|
self.facts['lsb']['codename'] = value
|
|
|
|
|
else:
|
|
|
|
|
return self.facts
|
|
|
|
|
|
|
|
|
|
if 'lsb' in self.facts and 'release' in self.facts['lsb']:
|
|
|
|
|
self.facts['lsb']['major_release'] = self.facts['lsb']['release'].split('.')[0]
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
def get_selinux_facts(self):
|
|
|
|
|
if not HAVE_SELINUX:
|
|
|
|
|
self.facts['selinux'] = False
|
|
|
|
|